15 lines
490 B
JavaScript
15 lines
490 B
JavaScript
var Student = /** @class */ (function () {
|
|
function Student(firstName, middleInitial, lastName) {
|
|
this.firstName = firstName;
|
|
this.middleInitial = middleInitial;
|
|
this.lastName = lastName;
|
|
this.fullName = firstName + " " + middleInitial + " " + lastName;
|
|
}
|
|
return Student;
|
|
}());
|
|
function greeter(person) {
|
|
return "Hello, " + person.firstName + " " + person.lastName;
|
|
}
|
|
var user = new Student("Jane", "M.", "User");
|
|
console.log(greeter(user));
|