Home / Questions / How will you print "Hello World" without semicolon in c programming Language?
Explanatory Question

How will you print "Hello World" without semicolon in c programming Language?

👁 854 Views
📘 Detailed Answer
🕒 Easy to Read
Read the answer carefully and go through the related questions on the right side to improve your understanding of this topic.

Answer with Explanation

You can use this below two code Code 1:

#include<stdio.h>
int main(void)
{
 switch(printf("Hello World 
"));
} 

Code 2:

#include<stdio.h>
int main(void)
{
 switch(printf("Hello World 
")){}
} 

Output
Hello World
Press any key to continue . . .