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.
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.