Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- class User {
- name: string;
- email: string;
- age: number;
- constructor(name: string, email: string,age: number){
- this.name = name;
- this.email = email;
- this.age = age;
- console.log('User Created: '+this.name);
- }
- }
- var john = new User('John Doe', 'jdoe@outlook.com', 34);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement