Tuesday 2 January 2018

program in c or c++ to print message without using any semicolon in program.

In this program we are simply use a if conditional statement to print  message without using any semicolon.Now let see the program :-


PROGRAM IN C TO PRINT MESSAGE WITHOUT USING SEMICOLON.

#include<stdio.h>

void main()
{
if(printf("hello"))
{}
}
 



PROGRAM IN C++ TO PRINT MESSAGE WITHOUT USING SEMICOLON.\

#include<iostream.h>

void main()
{
if(cout<<"hello"){}
}



No comments:

Post a Comment