In C or C++
if ( x ) statement1; else statement2;
For what value of x will both statements be executed?
x
I know
You can use this:
#include int main() { if (//some condition//) { IF:{ printf("Hello "); //Code for if block. } goto ELSE; } else { goto IF; ELSE:{ printf("world");//code for else block. } } return 0; }
Output: Hello world
Hello world