Skip to content
Related Articles

Related Articles

C | Operators | Question 13
  • Difficulty Level : Easy
  • Last Updated : 09 Feb, 2013




#include<stdio.h> 
int main(void
  int a = 1; 
  int b = 0; 
  b = a++ + a++; 
  printf("%d %d",a,b); 
  return 0; 
}


(A) 3 6
(B) Compiler Dependent
(C) 3 4
(D) 3 3


Answer: (B)

Explanation: See https://www.geeksforgeeks.org/sequence-points-in-c-set-1/ for explanation.

Quiz of this Question

Attention reader! Don’t stop learning now. Get hold of all the important C++ Foundation and STL concepts with the C++ Foundation and STL courses at a student-friendly price and become industry ready.

My Personal Notes arrow_drop_up
Recommended Articles
Page :