sspprriinnttff() -- STDIO Function (libc)

Format output
#iinncclluuddee <ssttddiioo.hh>
iinntt sspprriinnttff(_s_t_r_i_n_g, _f_o_r_m_a_t [ , _a_r_g ] ...)
cchhaarr *_s_t_r_i_n_g, *_f_o_r_m_a_t;

sspprriinnttff() formats and prints a string.  It resembles the function pprriinnttff(),
except that  it writes its  output into the  memory location pointed  to by
_s_t_r_i_n_g, instead of to the standard output.

sspprriinnttff() reads the string pointed to by _f_o_r_m_a_t to specify an output format
for each  _a_r_g; it then writes  every _a_r_g into _s_t_r_i_n_g, which  it ends with a
null character.  For a detailed discussion of sspprriinnttff()'s formatting codes,
see pprriinnttff().

If it wrote the formatted string correctly, sspprriinnttff() returns the number of
characters written.  Otherwise, it returns a negative number.

_E_x_a_m_p_l_e
For an example of this function, see the entry for ssssccaannff().

_S_e_e _A_l_s_o
pprriinnttff(), ffpprriinnttff(), lliibbcc, vvsspprriinnttff()
ANSI Standard, section 7.9.6.5
POSIX Standard, section 8.1

_N_o_t_e_s
The output  _s_t_r_i_n_g passed  to sspprriinnttff()  must be large  enough to  hold all
output characters.

Because  C  does not  perform  type  checking, it  is  essential that  each
argument match its format specification.
