9 Antworten
+ 4
a%b returns the remainder of division of a/b
+ 3
7/4 is taken as 1. So it is 1%64 which is 1
+ 3
No it is still performing the same operation of giving remainder
+ 1
so if % is in an equation 7/4% (8*8) then what is it doing here%
+ 1
I have same problem when finding an integer which is multiple of six plus one.
So I use n%6-1==0 .
However the result of 1%6 give me 1 which is wrong.
So I use n%6-1==0 and n/6>=1 to solve the problem
0
try putting 6-1 in paranthesis
here % is having more precedence than +operation
that is % is done first
when n=1,1%6=1 and then 1-1=0
that's why u r getting result as one
0
n%(6-1)
or simply put 5 instead
but o/p will be 5
- 1
so in this equation is it multiplying then?
- 1
what happens to the 64 then does % make the rest of the equation voided