+ 3
What is valu of %
8 Respostas
+ 5
it is used to get reminder of a number
lets says you have 14 as a number and you want to see what is remained after dividing by 3
14%3 ==> 14 -( 3x4) ==> 14 - 12 = 2
14%3 will give you 2
21%5=1
3%2=1
49%10=9
101%100=1
25%5=0
+ 4
for example:
5%2=1
14%4=2
50%10=0
33%10=3
I hope this example help u :)
+ 4
thanks all of you
for solve my problem
+ 3
% is not a value, it's rather an opporator.
It returns the rest of the value once it's devided, example:
7 % 2 = 1
because 7 / 2 = 3 with a rest of 1.
Another example:
12 % 10 = 2
• 12 / 10 = 1 with a rest of 2
13 % 7 = 6
• 13 / 7 = 1 with a rest of 6
https://code.sololearn.com/c1bKBG63l3Zy/?ref=app
+ 3
% is not a value. It's the remainder operator to find the remainder after an integer division...
+ 2
ali, scroll a bit up to see my explanation and examples on Modulo (%)
0
To give reminder in division
0
friends any on can help me with modulo !!! i can't understand it////