uriola
June 15, 2018, 12:59am
#1
Tell us what’s happening:
i dont get it
Your code so far
// Only change code below this line
var remainder = 11;
11 % 3 = 2
Your browser information:
User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/67.0.3396.87 Safari/537.36
.
Link to the challenge:
https://learn.freecodecamp.org/javascript-algorithms-and-data-structures/basic-javascript/finding-a-remainder-in-javascript
=
means assign the value on the right to the variable on the left. It isn’t like maths. You don’t need to figure what the actual value of the remainder of 11 and 3 is, JS will do that, you just need to set the value of the variable remainder
to the sum.
wadie
June 15, 2018, 1:47am
#3
Try this
// Only change code below this line
var remainder;
remainder = 11 % 3;
Which calculates 11%3 and assigns it to the variable remainder
uriola
June 15, 2018, 2:04am
#4
did not work
I put this
// Only change code below this line
var remainder = 11;
remainder = 11 % 3
It says I need to use You should use the % operator
uriola
June 15, 2018, 2:05am
#5
uriola:
var remainder = 11;
remainder = 11 % 3
ok this worked
var remainder = 11;
remainder = 11 % 3;