main( )
{
printf("%u\\n%x\\n%X\\n%e\\n%E\\n%f\\n%g\\n%G\\n%c\\n%s\\n%4d\\n
%4d\\n%.3f\\n%.11s\\n%10s\\n%-10s\\n",
455,32000,2000000000,455,455,455,455,1234567.89,1234567.89,1234567.89,1234567.89.'a',"this is a string",1,12345,123.94536,"Happy Birthday","Hello","Hello");
}
the output is: 455 1c7 1C7 1.234568e+06 1.234568E+06 1234567.890000 1.23457e+0.6 1.23457E+0.6 A This is a string 1 12345 123.945 Happy Birthday Hello Hello
1)why must type after #include? 2)why must place a % before conversion specifier (eg: %d ) 3)can u explain the "%4d" the output is " 1 ", what is the meaning of 4? 4)why there is a . before c.s (eg: %.11s) 5)why there is a - before c.s (eg: %-10s)
correction for the command #include main( ) { printf(“%u\n%x\n%X\n%e\n%E\n%f\n%g\n%G\n%c\n%s\n%4d\n %4d\n%.3f\n%.11s\n%10s\n%-10s\n”, 455,455,455,455,1234567.89,1234567.89,1234567.89,1234567.89, ‘A’, “This is a string”,1,12345,123.94536,“Happy Birthday”, “Hello” , “Hello”); }