C program without semicolon
By Ankita Chaterjee
(Student, Techno India Group of College,Kolkata)
If you are asked to write a program that will print something,but the program will have no semicolon. Then...probably you will have to think
a bit. Few will say how it's possible?
Well here is the program in C, that will print welcome to hackingheart. How the program is working that i am leaving on you.
Try and find out the logic. Of course if you have problem then put a comment, i will reply.
include<stdio.h>
void main()
{
if ( printf("Welcome to hackingheart\n"))
{
if ( printf("successful"))
{}
}
else
{
if ( printf("Failure"))
{}
}
}
No comments:
Post a Comment