Skip to content

Murwarid Fazal - Week 3 Assignment - #14

Open
murwaridfazal-art wants to merge 2 commits into
HackYourAssignment:mainfrom
murwaridfazal-art:main
Open

murwaridfazal-art wants to merge 2 commits into
HackYourAssignment:mainfrom
murwaridfazal-art:main

Conversation

@murwaridfazal-art

Copy link
Copy Markdown

No description provided.

@RHSebregts
RHSebregts self-requested a review November 25, 2026 22:05
@RHSebregts RHSebregts added Review in progress Reviewed This assignment has been reivewed by a mentor and a feedback has been provided and removed Review in progress labels Nov 25, 2026

@RHSebregts RHSebregts left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi!

Great work on this! I left some small comments, but functionally it's all there.

Well done!

Thank you or your work, and great luck with the rest of the course!

Best wishes,

Robbert-Jan

Comment thread task-1/book.js

if (normalizedSearch === '') {
return false;
}

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indentation

Comment thread task-1/book.js
return false;
}

return normalizedTitle.includes(normalizedSearch);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

indentation

Comment thread task-2/parse-date.js
// Your code here
function parseDateString(dateString) {
const [format, dateValue] = dateString.split(' ');
const parts = dateValue.split('-').map(Number);

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the .map(Number) is fancy, can you tell me how that works? How does it get the value?

Comment thread task-2/parse-date.js
year = parts[2];
}

return { day, month, year };

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

so if my format is banana, what happens?

Comment thread task-3/date.js

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm!

Comment thread task-4/cleanup.js
} else {
console.log("Status: Hot");
function calculateWindChill(celsius, windSpeed) {
return 13.12 + (0.6215 * celsius) - (11.37 * Math.pow(windSpeed, 0.16)) + (0.3965 * celsius * Math.pow(windSpeed, 0.16));

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'll always advise that these kind of complex calculations are better off broken up over smaller bits, and shouldn't go directly into your return statement. There's a lot of components to it that could break, and it's pretty hard to figure out which part was the wrong one.

Comment thread task-4/cleanup.js
Comment on lines +34 to +40
console.log("Weather Report for " + cityName);
console.log("Temperature: " + celsius + "°C");
console.log("Temperature: " + fahrenheit + "°F");
console.log("Temperature: " + kelvin + "K");
console.log("Status: " + status);
console.log("Wind chill in " + cityName + ": " + windChill.toFixed(2) + "°C");
console.log("---");

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is all correct! To make your own life a bit easier, you might want to read about Template Literals. They make it so much easier to write logs and statements like this!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Reviewed This assignment has been reivewed by a mentor and a feedback has been provided

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants