PLAY WITH CODING

Home Basic Program If & Else Loops Conversion Pattern logo

Program Based on If & Else

rogram to print HELLO WORLD without semicolon

Input - Output

Output
Hello World

Algorithm

Step 1: START

Step 2: print Hello World in if condition:

   if(printf(" Hello World ")) { }

Step 4: END

CODE


/* print hello world without semicolon */
#include  <stdio.h>
int main()
{
   if(printf(" HELLO WORLD "))
    {  }
    return 0;
}


/* print hello world without semicolon */
#include <iostream>
using namespace std;
int main()
{
   if(cout<<" HELLO WORLD ")
    {  }
    return 0;
}

OutPut

HELLO WORLD