466
|
1 <refentry id="printf">
|
|
2
|
|
3 <refnamediv>
|
|
4 <refname>printf</refname>
|
|
5 <refname>fprintf</refname>
|
|
6 <refname>sprintf</refname>
|
|
7 <refpurpose>formatted output</refpurpose>
|
|
8 </refnamediv>
|
|
9
|
|
10 <refsynopsisdiv>
|
|
11
|
|
12 <funcsynopsis>
|
|
13 <funcsynopsisinfo>
|
|
14 #include <stdio.h>
|
|
15 </funcsynopsisinfo>
|
|
16 <funcprototype>
|
|
17 <funcdef><function>printf</function></funcdef>
|
|
18 <paramdef>char *<parameter>control</parameter></paramdef>
|
472
|
19 <paramdef>...</paramdef>
|
466
|
20 </funcprototype>
|
|
21
|
|
22 <funcprototype>
|
|
23 <funcdef><function>fprintf</function></funcdef>
|
|
24 <paramdef>FILE *<parameter>fp</parameter></paramdef>
|
|
25 <paramdef>char *<parameter>control</parameter></paramdef>
|
|
26 <paramdef>...</paramdef>
|
|
27 </funcprototype>
|
|
28
|
|
29 <funcprototype>
|
|
30 <funcdef><function>sprintf</function></funcdef>
|
|
31 <paramdef>char *<parameter>string</parameter></paramdef>
|
|
32 <paramdef>char *<parameter>control</parameter></paramdef>
|
|
33 <paramdef>...</paramdef>
|
|
34 </funcprototype>
|
|
35 </funcsynopsis>
|
|
36
|
|
37 </refsynopsisdiv>
|
|
38
|
|
39 <refsect1><title>Description</title>
|
|
40 <para>
|
|
41 Thse three functions are used to place numbers and strings on
|
|
42 the output in formatted, human readable form.
|
|
43 </para>
|
|
44 <para>
|
|
45 Fprintf places its output on the file "fp", printf on the
|
|
46 standard output, and sprintf in the buffer pointed to by
|
|
47 "string". NOTE that it is the user's responsibility to ensure
|
|
48 that this buffer is large enough.
|
|
49 </para>
|
|
50 </refsect1>
|
542
|
51
|
|
52 <refsect1><title>See Also</title>
|
|
53 <para>
|
|
54 Kernighan & Ritchie pages 145-147.
|
|
55 <link linkend="Putc">putc()</link>,
|
|
56 <link linkend="scanf">scanf()</link>
|
|
57 </para>
|
|
58 </refsect1>
|
|
59
|
466
|
60 </refentry>
|