what is the output for the code :
main()
{
int i,j;
printf("%d %d ",scanf("%d%d",&i,&j));
}
Answer Posted / carol
scanf will return the number of arguments that are scanned
successfully from keyboard.So first it will get two values
from the user and return two . So the printf statement
prints 2 for the first %d and since there is no specific
value for second %d it will print garbage value.
| Is This Answer Correct ? | 1 Yes | 1 No |
Post New Answer View All Answers
How can I open files mentioned on the command line, and parse option flags?
Which is the best website to learn c programming?
What is an array? What the different types of arrays in c?
Can you tell me how to check whether a linked list is circular?
What is a pointer in c plus plus?
Do pointers store the address of value or the actual value of a variable?
What is difference between structure and union?
Explain how can you tell whether two strings are the same?
What are terms in math?
What are the types of i/o functions?
Explain what is the difference between text files and binary files?
What is meant by preprocessor in c?
how is the examination pattern?
What is pointers in c with example?
If jack lies on Mon, Tue Wed and jill lies on Thursday, Friday and Saturday. If both together tell they lied yesterday. So c the given options and then c cos in the given dates one will be saying the truth and one will be lying. I got Thursday as option because jack is saying the truth he lied yest but jill is lying again as he lies on that day.