0

What is the result of 4 % 5 ? I found this question in js challenge, thanks in advance.

29th Nov 2016, 4:42 AM
Randa Elkhashen
Randa Elkhashen - avatar
4 Antworten
+ 2
It is 4. If we try to do modulo for a number(4) with a number greater than it(5) then the result would be the number(4) itself. So 4%5=4
29th Nov 2016, 4:58 AM
Sai Kishore
Sai Kishore - avatar
+ 2
So, If that was 5 % 4 = 1, Is it correct?
29th Nov 2016, 5:04 AM
Randa Elkhashen
Randa Elkhashen - avatar
+ 1
@Randa Elkhashen: Yes
29th Nov 2016, 5:20 AM
Jacques Navarro
Jacques Navarro - avatar
0
4%5=0,because the remainder is in decimal.....
29th Nov 2016, 7:37 AM
Rohan Yadav
Rohan Yadav - avatar