Why the code below with input value 36, output is 4 but not 1? | SoloLearn: Learn to code for FREE!

+2

Why the code below with input value 36, output is 4 but not 1?

So, I can't solve it. Please help me? https://code.sololearn.com/W554eG5rM5pa/?ref=app

1/23/2021 2:39:35 PM

Egor Tonchev(EGO)

2 Answers

New Answer

+2

Yes, it is really works fine. Thanks to You, Abhay

0

This should work fine, var nmbrvol= (numberVolunteers% 5==0)?0:5-numberVolunteers%5; console.log(nmbrvol);