main()
{
int a,b;
printf("%d,%d",scanf("%d%d",&a,&b));
}


=> do u mean above program's output...
=>output will be:2,whatever you enter value for b.
=>because scanf is a library fn which will return how many
arguements it processes, and second value
you are right mr.Satya but i found my self unable to
understand that for the first time scanf returns the no of
successful matches but how for the second time it returns
the value of 'b'.while a function should return the
same 'r' value every time.

Answer Posted / gulam sarwar chuwdhury

The output :2,the value of b

Is This Answer Correct ?    7 Yes 2 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What will the code below print when it is executed?   int x = 3, y = 4;         if (x = 4)                 y = 5;         else                 y = 2;         printf ("x=%d, y=%d ",x,y);

1343


What is the difference between text files and binary files?

667


What is the difference between scanf and fscanf?

656


Suppose we have a table name EMP as below. We want to perform a operation in which, I want to change name ‘SMITH’ from as ‘SMITH JAIN’. Also I want to change the name of the column from ENAME to E_NAME. EMPNO ENAME JOB MGR HIREDATE SAL 7369 SMITH Coder 7902 17-DEC-80 800 7499 ALLEN SALESMAN 7698 20-FEB-81 1600 7521 WARD SALESMAN 7698 22-FEB-81 1250

1496


a sequence of bytes with one to one corrspondence to those in the external device a) sequential addressing b) address c) byte code d) none

712






find the value of y y = 1.5x+3 for x<=2 y = 2x+5 for x>2

1521


What is data types?

628


What do you mean by c?

578


What are logical errors and how does it differ from syntax errors?

647


what is the significance of static storage class specifier?

1650


cavium networks written test pattern ..

3584


What are enums in c?

651


Explain the use of 'auto' keyword

668


Explain how do I determine whether a character is numeric, alphabetic, and so on?

644


I need a help with a program: Write a C program that uses data input in determining the whole of points A and a whole of circles B. Find two points in A so that the line which passes through them, cut through the maximum number of circles.

1486