Skip to content

we answered the questions as a pair Fatma Degirmenci /Jesus del Moral #329

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

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
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
6 changes: 4 additions & 2 deletions questions-and-reviews/questions/0.md
Original file line number Diff line number Diff line change
Expand Up @@ -19,10 +19,12 @@ const result2 = logSum(10, 32);
```

a) what will `result1` evaluate to? Explain your answer
-The calculateSum function takes two arguments (a and b), adds them together, and returns the result.

b) What will `result2` evaluate to? Explain your answer
-The logSum function adds a and b, then logs the result to the console using console.log(a + b).

c) Try to summarise the main difference between `logSum` and `calculateSum`
-calculateSum returns the result of a + b, allowing you to use that value elsewhere in your code.


{YOUR ANSWERS HERE}
-logSum prints the result to the console but does not return anything.
5 changes: 4 additions & 1 deletion questions-and-reviews/questions/1.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,7 @@
// Remember to write your prediction first, before you run this file

const currentYear = 2023;
currentYear();
currentYear();