4. Can I See Results?

With printf()

image

If neither you nor anybody else could see your program’s output, there would be little use for your program! Ultimately, you have to be able to view the results of a program. C’s primary means for output is the printf() function. There is no actual command that performs output, but the printf() function is a part of every C compiler and one of the most-used features of the language.

What printf() Does

In a nutshell, printf() produces output on your screen. As Figure 4.1 shows, ...

Get Absolute Beginner’s Guide to C, 2nd Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.