/*what is the output for the code*/
void main()
{
int r;
r=printf("naveen");
r=printf();
printf("%d",r);
getch();
}

Answer Posted / amegha

r=printf() sttmnt will produce an error as - too few
parameters in printf().
It needs any argument value.

r=printf("naveen") returns the no of characters printed.
here 6.

Is This Answer Correct ?    3 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Explain the difference between malloc() and calloc() in c?

838


Linked list is a Linear or non linear explain if linear how it working as a non linear data structures

1984


Explain zero based addressing.

816


Explain with the aid of an example why arrays of structures don’t provide an efficient representation when it comes to adding and deleting records internal to the array.

2940


What are the advantages and disadvantages of a heap?

964


int i=10; printf("%d %d %d", i, i=20, i);

1341


Using functions, write a program that multiplies two arrays. Use the following functions: - Function ReadArray - Function MultiplyArrays - Function DisplayArrays

2147


What are data structures in c and how to use them?

935


Explain what happens if you free a pointer twice?

848


What are dangling pointers in c?

865


What are structures and unions? State differencves between them.

885


What are control structures? What are the different types?

876


what do you mean by inline function in C?

865


What is the advantage of a random access file?

904


Create a structure to specify data on students as given below: Roll number, Name, Department, Course, and Year of joining. Assume that there are not more than 450 students in the collage. (a) Write a function to print the names of all students who joined in the last 3 years. (b) Write a function to print the data of a student whose roll numbers are divisible by 4.

911