let player = {
name: "default_name",
weapon: "Pistol",
exp: "Pro",
// defining method
setName: function(name) {
},
getName: function() {
},
showInfo: function() {
console.log(`${this.name} uses ${this.weapon} and is ${this.exp} level player in STBattleRoyal`);
}
};
player.setName("John Wick");
player.showInfo();
Please explain me a correct code ASAP