Does sprintf put null character?



Does sprintf put null character?..

Answer / Rishi Kumar

Yes, the sprint function in C does append a null character () to the end of the output string.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More C Interview Questions

write c program to display output 10(10+20)+(10+20+30)+ ... n term

0 Answers   Hindustan Gum Chemicals,


A C E G H +B D F A I ------------ E F G H D

1 Answers   Infosys,


What is meant by int fun const(int a, int b) { .... ... }

1 Answers  


how can i get output the following... 5 4 3 2 1 4 3 2 1 3 2 1 2 1 1 and 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 plz plz...

3 Answers  


What is uint8 in c?

1 Answers  


What is the use of in c?

1 Answers  


Explain what are global variables and explain how do you declare them?

1 Answers  


Given an array A[n+m] of n+m numbers, where A[1] ... A[n] is sorted and A[n+1] ... A[n+m] is sorted. Design a linear time algorithm to obtain A[1...n+m] sorted using only O(1) extra space. Time Complexity of your algorithm should be O(n) and Space Complexity O(1).

0 Answers  


Do you know null pointer?

1 Answers  


Is that possible to add pointers to each other?

1 Answers  


How can I read in an object file and jump to locations in it?

1 Answers  


52.write a “Hello World” program in “c” without using a semicolon? 53.Give a method to count the number of ones in a 32 bit number? 54.write a program that print itself even if the source file is deleted? 55.Given an unsigned integer, find if the number is power of 2?

25 Answers   Datamatics, Solartis, TCS, ThinkBox, Trine,


Categories