CHAPTER 4CHARACTER STRINGS AND FORMATTED INPUT/OUTPUT

You will learn about the following in this chapter:

• Function:

strlen()

• Keywords:

const

• Character strings

• How character strings are created and stored

• How you can use scanf() and printf() to read and display character strings

• How to use the strlen() function to measure string lengths

• The C preprocessor’s #define directive and ANSI C’s const modifier for creating symbolic constants

This chapter concentrates on input and output. You’ll add personality to your programs by making them interactive and using character strings. You will also take a more detailed look at those two handy C input/output functions, printf() and scanf(). With these two functions, you have the program tools ...

Get C Primer Plus, Fifth Edition now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.