Thursday, August 16, 2007

interesting facts and programs related to C programming.

Here are some interesting facts and programs related to C programming.

* We all know that to print something in the output screen we have to use printf statement and a printf statement statement ends with a semi-colon according to the syntax. But to print something in the output screen without using semi-colon we can make use of if statement with printf statement. Try executing the following code in Turbo C after including the header files.

void main()

{

if(printf(”Hi”))

{

}

}

The Hi given inside the printf will be displayed in the output screen. Since I didnt use the getch() statement, you’ll have to press alt+F5 to view the output screen. I’ll post few other small programs later which you may find useful for debugging competitions in other college symposiums.

Yours buggingly

Vinod…(my friend)

No comments: