+ 4
How this code show output 1211 đ¨đ¨đ¨
#include <iostream> using namespace std; int main() { int x=1,y=1,z=1; cout<<(++x||++y&&++z); cout<<x<<y<<z; return 0; }
2 Answers
+ 4
++x is 2, equivalent to True.
Hence the && expression isn't evaluated.
Hence, the first output is 1.
Since only x is incremented, the rest of the output is 211
+ 1
what you want to show