main(){char *str;scanf("%s",str);printf("%s",str); }The error in the above program is:

a) Variable 'str' is not initialised

b) Format control for a string is not %s

c) Parameter to scanf is passed by value. It should be an address

d) none


No Answer is Posted For this Question
Be the First to Post Answer

Post New Answer

More C Interview Questions

why should i select you?

21 Answers   Wipro,


hi friends how r u as soon in satyam my interview is start but i m very confusued ta wat i do plz help me frndz wat can i do plz tell me some question and answers related with "C" which r asked in the interview .

0 Answers   Aegis, CDAC, Infosys,


main() { inta=10,b=20; a>=5?b=100:b=200; printf("%d ",b); }

0 Answers   Wilco,


What is the use of function overloading in C?

0 Answers   Ittiam Systems,


`write a program to display the recomended action depends on a color of trafic light using nested if statments

0 Answers  


How can I handle floating-point exceptions gracefully?

0 Answers  


What are the advantages and disadvantages of pointers?

0 Answers  


Can a file other than a .h file be included with #include?

0 Answers   Aspire, Infogain,


what is the purpose of the code, and is there any problem with it. unsigned int v[10]; unsigned int i = 0; while (i < 10) v[i] = i++;

2 Answers   Google,


what is the diference between pointer to the function and function to the pointer?

2 Answers   Infosys,


What is the general form of #line preprocessor?

0 Answers  


In how much time you will write this c program? Prime nos from 1 to 1000

2 Answers   TCS,


Categories