Skip to content

Glossary: C Basics

snprintf

Works like printf but writes into a char array. It never writes more than the buffer size and always ends with '\0', so it is the safe way to build or copy strings.

Where the book teaches it

Related terms

Stringstrcpyprintf