vsprintf, vsnprintf - print formatted output
#include <stdarg.h> #include <stdio.h> int vsprintf(char *s, const char *format, va_list ap); int vsnprintf(char *s, size_t n, const char *format, va_list ap);
Refer to vfprintf().