-
Notifications
You must be signed in to change notification settings - Fork 38
Cherrelle-Morrison-Assignment-submission #25
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Cherrelle-Morrison-Assignment-submission #25
Conversation
dimitriharding
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please see review changes.
| const array = [1, 2, 3, 4, 5, 6, 7, 8, 9, 10]; | ||
|
|
||
| function printElement(item){ | ||
| console.log("The current element is "+item) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You are going to be mad at yourself, but the instructions wanted you to use the template literal syntax instead of quotes.
| console.log("The current element is "+item) | |
| console.log(`The current element is ${item}`) |
| // and print "Geology paper marked" | ||
| return new Promise((resolve,reject) => { | ||
| setTimeout(() => { | ||
| console.log("Geology paper marked"); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ideally, we would have wanted to resolve the text from the promise rather than printing it in the promise, but no marks will be deducted since the instructions could have been misinterpreted.
| class Vehicle{ | ||
| constructor(wheels, bodyType){ | ||
| this.wheels = wheels; | ||
| this.bodyType = bodyType; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Since classes are used to reduce code, you were expected to define the whatIsMyName method on the "Vehicle" class. So that way you wouldn't have to add it to all of the child classes.
No description provided.