Conversation
marcianoviereck
left a comment
There was a problem hiding this comment.
Overall it looks good! Just some smaller style remarks and could you split your homework up in separate files?
|
|
||
| //3 | ||
| let x ; | ||
| console.log ("the value of my variable x will be:EvenNumber"); |
There was a problem hiding this comment.
Are you sure that the value of x is EvenNUmber ?
(I don't think it will be that value)
| console.log ("the value of my variable x will be:EvenNumber"); | ||
| console.log (x); | ||
| x = 8 ; | ||
| console.log ("the value of my variable x will be:EvenNumber"); |
There was a problem hiding this comment.
Are you sure that the value of x is EvenNumber?
|
|
||
| //4 | ||
| let y = "HackYourFuture" | ||
| console.log ("the value of the string is "+"HackYourFuture") |
There was a problem hiding this comment.
Please don't forget to add ; at the end of the line:)
| console.log(a); | ||
|
|
||
| let highest; | ||
| if (z>a){ |
There was a problem hiding this comment.
Good! You can also use math.max, but this solution is fine:)
|
|
||
|
|
||
| //6 | ||
| let FavoriteAnimals = [ ]; //6.1 |
There was a problem hiding this comment.
You should not use capital letters for the variable names.
So FavoriteAnimals should be favoriteAnimals.
There was a problem hiding this comment.
Can you fix this one?
| console.log(FavoriteAnimals); //6.3 | ||
| let MyFavoriteAnimals = [ 'Deer' , 'Horse' , 'Koala' ]; //6.4 | ||
| console.log (MyFavoriteAnimals); //6.5 | ||
| let NewMyFavoriteAnimals = MyFavoriteAnimals.concat(['baby pig']); //6.6 |
There was a problem hiding this comment.
Ah nice, you can also use
MyFavoriteAnimals.push('baby pig');
Which might be an easier solution
|
|
||
| //8.5 | ||
| if (typeof(type1)===typeof(type2)) | ||
| {console.log('type1 and type2 are SameType');} |
There was a problem hiding this comment.
Tip: The code is easier to read if you add more spaces in between the if statement, like this:
if (typeof(type1)===typeof(type3)) {
console.log('type1 and type3 are SameType');
} else {
console.log('type1 and type3 are NOT SameType');
}
|
|
||
|
|
||
| //9 | ||
| let X = 7 ; |
There was a problem hiding this comment.
please use lowercase x
There was a problem hiding this comment.
And this one, then the homework is approved!
| @@ -0,0 +1,121 @@ | |||
| //1 | |||
There was a problem hiding this comment.
I see that you did all your homework in one file, but the assignment was to make one file for each part of the homework:
For all the following exercises create a new .js file. Try to find a proper name for each file or make a small comment about what it does inside for future reference.
There was a problem hiding this comment.
Thank you for your review, I'v made changes as advised, could you please re-check?
|
Dear @RiamAlali Thanks a lot for addressing Marciano's feedback - very professional indeed! @marcianoviereck Can you check if there is anything left to be done? |
|
@wouterkleijn Yes the homework for week 2 is now approved, but I still need to check the homework for week 3.. |
marcianoviereck
left a comment
There was a problem hiding this comment.
Some very minor changes left, over all its good just two small things!
|
|
||
|
|
||
| //6 | ||
| let FavoriteAnimals = [ ]; //6.1 |
There was a problem hiding this comment.
Can you fix this one?
|
|
||
|
|
||
| //9 | ||
| let X = 7 ; |
There was a problem hiding this comment.
And this one, then the homework is approved!
No description provided.