Skip to content

Glossary: C Basics

fgets

Reads a whole line into a buffer, never more than fits, and returns NULL at the end of input. It keeps the newline at the end of the line.

Where the book teaches it

Related terms

strcspnStandard streamsNULL