Skip to content
Open
Show file tree
Hide file tree
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion Sprint-1/1-key-exercises/4-random.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,6 @@ const num = Math.floor(Math.random() * (maximum - minimum + 1)) + minimum;

// num represents a random number in the interval [1,100]
// First, it starts with 100 - 1 + 1, which is equals to 100
// Secondly, it multiply with Math.random(), which the function returns any number in the interval [0,1]
// Secondly, it multiply with Math.random(), which the function returns any number in the interval [0,1)
// Thirdly, Math.floor() rounds down and returns the largest integer less than or equal to a given number
// Finally, it adds 1
2 changes: 1 addition & 1 deletion Sprint-1/3-mandatory-interpret/1-percentage-change.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ console.log(`The percentage change is ${percentageChange}`);
// Read the code and then answer the questions below

// a) How many function calls are there in this file? Write down all the lines where a function call is made
// Line 4, 5, 10
// 5 (2 × Number(), 2 × replaceAll(), 1 × log())

// b) Run the code and identify the line where the error is coming from - why is this error occurring? How can you fix this problem?
// It's missing a comma between the arguments at line 5 in replaceAll() method
Expand Down
4 changes: 3 additions & 1 deletion Sprint-1/4-stretch-explore/chrome.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,4 +26,6 @@ It displays an alert with a textfield where you can enter some text, e.g. John.

What is the return value of `prompt`?

The string returned from the textfield what the user has entered otherwise null if the user left it blank.
If the user has entered text, the return value is a string containing the entered text.
If the user leaves the text field blank and clicks the OK button, the return value is an empty string.
If the user enters a name or leaves the text field blank but clicks the Cancel button, the return value is null.
Comment on lines +29 to +31
Copy link
Contributor

Choose a reason for hiding this comment

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

This is accurate but could be simplified. Some of the info is not very useful.

Knowing how to explain or describe code is an important skill in software development.

Suggestion: Use AI to help you figure out how to make the description more concise.