int main (void)
{
if(printf("Print whatever you want"))
{
}
}
try to usecondition ? value if true : value if falseor: if (printf ("Hello")) {}
If you forget the semicolon, your program won't compile.
use cout << simple
The print with semi - colon is used to write the text one after the other, without giving the space between them whereas the print with colon is used to type the text one after the other, with giving plenty of spaces between them.
#include<stdio.h> #include<conio.h> void main() { if(printf("hello world")){} if(getch()){} }
The only way i see is to use : using the right file descriptor
printf("%u %+d %+d",200,200,-200); //will print 200 +200 -200
With functions like ecvt, fcvt, gcvt.
Answerwell if it is about the include statement only then your answer goes simple. extern "C"{int printf(const char *format,..);}int main(){printf("Hello world");}coz all the include statement does is copy the requested file at the asked location.
It is very easy. The program begins here..... /*Program to sum and print numbers without creating variables*/ #include<stdio.h> main() { clrscr(); printf("%d+%d=%d",5,2,5+2); getch(); } /*Program ends here*/ Now just by changing the numbers in the "printf" statement we can add, subtract, multiply and divide the numbers without using variables. Hence the problem is solved..........
#include <stdio.h> int main (void) { puts ("the name"); return 0; }
A continue statement is used to "branch" to the end of a loop without exiting the loop. If we wish to exit the loop entirely, use a break or return statement.for (int i=1; i