GeekInterview.com
   Home |  Tech FAQ  |   Interview Questions |  Placement Papers |  Tech Articles |  Learn |  Freelance Projects |  Online Testing |  Geeks Talk |  Job Postings |  Knowledge Base | Site Search |  Add/Ask Question

  GeekInterview.com  >  Interview Questions  >  Programming  >  C

 Print  |  
Question:  C if condition Puzzle

Answer: What's the "condition" so that the following code
snippet prints both HelloWorld !

if "condition"
printf ("Hello");
else
printf("World");


September 09, 2008 16:11:26 #4
 rashmi.mohanty J2EE Expert  Member Since: September 2008    Total Comments: 8 

RE: C if condition Puzzle
 
void main(){ if ( ! ( printf("Hello ") ) ) printf("Hello"); else printf("World"); }
     

 

Back To Question