composition/source/logic/identity.ts
2025-03-03 06:15:30 +00:00

15 lines
269 B
TypeScript

class Identity {
private title: string;
private name: string;
public constructor(title: string, name: string) {
this.title = title;
this.name = name;
}
public introduce(): void {
show(`Hi! My name is ${this.name} and i'm the ${this.title} here.`);
}
}