first commit

This commit is contained in:
Volodya
2023-10-19 12:29:42 +03:00
commit 4b192915ed
15 changed files with 655 additions and 0 deletions

14
user.js Normal file
View File

@@ -0,0 +1,14 @@
function User(name, age) {
this.name = name;
this.age = age;
this.displayInfo = function () {
console.log(
`Имя: ${this.name} Возраст: ${this.age}`
);
};
}
User.prototype.sayHi = function () {
console.log(`Привет, меня зовут ${this.name}`);
};
module.exports = User;