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

Answer Posted / praveen

printf writes the data to console
sprintf writes the data to an array

Is This Answer Correct ?    5 Yes 5 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can I have a reference as a data member of a class? If yes, then how do I initialise it?

931


what are the iterator and generic algorithms.

1686


What is unary operator? List out the different operators involved in the unary operator.

791


Can turbo c++ run c program?

836


what is a reference variable in C++?

905


What is fflush c++?

779


Write about the stack unwinding?

842


What things would you remember while making an interface?

777


What is the most common mistake on c++ and oo projects?

735


What size is allocated to the union variable?

806


What is pointer with example?

751


Can you please explain the difference between using macro and inline functions?

744


Define friend function.

789


Can c++ do everything c can?

817


Why c++ is better than c language?

795