0
Can anyone tell me the answer for this question int X=9 and X%=11,printf("%d",X).what is the value of X?
C language
6 Antworten
+ 1
% - indicates Modulus operator, that gives the remainder.
X%=11- > X = X%11 = 9%11 =9 - > 9 can not be divided by 11. So, remainder is 9. So, Is the answer.
Hope this helps...!!!
0
It's 9
0
tq Agent_I can u pls tell me the process
0
Nagadeepthi
The % is a modulo operation, it calculates the remainder of a division operation. X = 9, X %= 11, so it can be written as x = x % 11.
9 divided by 11 has a quotient of 0 and has a remainder of 9
9 = 11 * 0 + 9
0
tq Agent_I
0
tq Nagendra