ProgrammingHard
printf("%d", (3 > 2) > 1); What is printed?
- A. 1
- B. 2
- C. 0
- D. 3
Correct answer: C. 0
The first comparison yields 1, and 1 > 1 is false, giving 0.
More C Programming questions
- printf("%d %d", 10 - 2 - 3, 2 ^ 3 ^ 1); What is printed?
- printf("%d", powmod(2, 100, 1000000007)); where powmod is standard binary exponentiation with 64-bit intermediates. What is printed?
- printf("%lld", (999999999LL 999999999LL) % 1000000007LL); What is printed?
- printf("%d %d", -17 % 5, 17 % -5); What is printed in C99?
- printf("%d", (-17 % 5 + 5) % 5); What is printed in C99?
- What is printed? c #include <stdio.h> int main(void) { int a[] = {1, 2, 3, 4, 5, 6}; int l = a, r = a + 5; while (l < r) { int t = l; l++…