1 <!DOCTYPE HTML PUBLIC
"-//W3O//DTD W3 HTML 2.0//EN">
2 <!-- This collection of hypertext pages is Copyright 1995, 1996 by Steve Summit. -->
3 <!-- This material may be freely redistributed and used -->
4 <!-- but may not be republished or sold without permission. -->
7 <link rev=
"owner" href=
"mailto:scs@eskimo.com">
8 <link rev=
"made" href=
"mailto:scs@eskimo.com">
9 <title>Functions
</title>
10 <link href=
"sx14c.html" rev=precedes
>
11 <link href=
"sx14e.html" rel=precedes
>
12 <link href=
"sx14.html" rev=subdocument
>
17 <p>Functions can't return arrays,
18 and it's tricky to write a function as if it returns an array
19 (perhaps by simulating the array with a pointer)
20 because you have to be careful about allocating the memory that
21 the returned pointer points to.
22 </p><p>The functions we've written have all accepted a well-defined,
23 fixed number of arguments.
24 <TT>printf
</TT> accepts a variable number of arguments
25 (depending on how many
<TT>%
</TT> signs there are
27 but we haven't seen how to declare and write functions that do this.
31 <a href=
"sx14c.html" rev=precedes
>prev
</a>
32 <a href=
"sx14e.html" rel=precedes
>next
</a>
33 <a href=
"sx14.html" rev=subdocument
>up
</a>
34 <a href=
"top.html">top
</a>
37 This page by
<a href=
"http://www.eskimo.com/~scs/">Steve Summit
</a>
38 //
<a href=
"copyright.html">Copyright
</a> 1995,
1996
39 //
<a href=
"mailto:scs@eskimo.com">mail feedback
</a>