а в местот тетрадей - PhotoShop- послать куда подальше.
class User {
constructor(...args) {
args.forEach(elem => this[elem] = elem)
}
get(blabla) {
return this[blabla];
}
}
let a;
let b;
let c;
let obj; {
a = 0;
b = "+";
c = "gvfbd";
obj = new User(a, b, c);
}
console.log(obj[a])
console.log(obj.get(a))