Input output function questions and answer with explanation



14 comments:

hitesh said...

these are really very very nice questions and i found it to be very useful and i run all the programs and accuracy is 100% of the answers of these questions.

Anonymous said...

nice

Rethe said...

Its really amazing site for beginners..
especially pointer in c tutor is really clear and excellent...
thanks

Unknown said...

write a program to multiplication of a 3x3 matrix

Priyanka kumari said...

Hi kapil,
Go through the following link for multiplication of matrix :
http://cquestionbank.blogspot.com/2008/01/write-c-program-for-multiplication-of.html

Anonymous said...

good

Anonymous said...

very good

Anonymous said...

great mama

latha said...

#include
void main()
{
int a=1,b=3,c=2;
a=(a>=b>=c?100:200);
printf(”\n%d”,a);

getch();

}
what is the out put for this

Priyanka kumari said...

Hi Latha
Output will be 200

In c any condition operation return 1 if it is true otherwise 0

Since
a>=b>=c
1>=3>=2
(1>=3)>=2 //Condition is true
1>=2
0 //Condition is false

Anonymous said...

int a=200,b=300;
long int x=a*b;
printf("%d",x);

why does not x print proper o/p ?

Anonymous said...

pls run this code to get the output:

int a=200,b=300;
long int x=a*b;
printf("%ld",x);

Note: plz use "ld" as specifier since x is "long int"

Anonymous said...

Very usefull site

Unknown said...

int printf( const char *var,...);//prototype
int printf(const char *v,...)
{
}