0
Why output is 5?
#include<stdio.h> int main() { int b=5; b%=7; printf("%d",b); return 0; }
1 Answer
+ 4
b = 5
b %= 7 is same like b = b % 7
which is b = 5 % 7 = 5
print(b) output is 5
% is modulus which return remainder of a/b(5/7)
You probably need to revise your course again especially operation operator and stuff.