What is the Difference between "printf" and "sprintf"?

Answer Posted / namitha

printf is used to write the data in its format.
sprintf is used to write formatted data to string.

Is This Answer Correct ?    21 Yes 8 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can static member variables be private?

711


How many different levels of pointers are there?

759


Do class method definitions?

668


How c functions prevents rework and therefore saves the programers time as wel as length of the code ?

724


How do you invoke a base member function from a derived class in which you’ve overridden that function?

675






Why we use #include iostream in c++?

674


Is c++ vector dynamic?

646


Is set c++?

658


What is the extraction operator and what does it do?

700


Should I learn c or c++ first?

657


What is a modifier in c++?

719


What is c++ code?

680


What do manipulators do?

665


What is scope in c++ with example?

724


What is the use of structure in c++?

635