appending int to string c code example Example: c str add int char buf[12]; snprintf(buf, 12, "FPS: %d", framesCount);