What is the difference between printf() and puts() in C?

前端 未结 10 2118
长发绾君心
长发绾君心 2020-12-07 07:27

I know you can print with printf() and puts(). I can also see that printf() allows you to interpolate variables and do formatting.

10条回答
  •  天涯浪人
    2020-12-07 07:40

    the printf() function is used to print both strings and variables to the screen while the puts() function only permits you to print a string only to your screen.

提交回复
热议问题