## Exercise 3

 1. In this exercise, we will practice working with object files and
    archives (static libraries) a little.
 2. We will start by creating an empty directory. Let's call it
    ‹ex3›.
 3. In that directory, let's create a 3-part program, made of
    ‹main.c›, ‹hello.c› and ‹bye.c›.  We will also need
    ‹greetings.h›.
 4. In each of the ‹.c› files, there will be a single function. In
    ‹hello.c›, it'll be ‹void hello()›, in ‹bye.c› it will be ‹void
    bye()› and in ‹main.c›, it'll be ‹int main()›.
 5. Our ‹greetings.h› will look like this:
    
        void hello( void ); /* C */
        void bye( void );
    
    There will only be those two lines. We can use ‹greetings.h› by
    using an ‹#include› statement, like this:
    
        #include "greetings.h" /* C */

 6. Each of ‹hello()› and ‹bye()› will simply write a message using
    ‹puts›.  You can choose the message. And ‹main()› will simply
    call ‹hello()› and ‹bye()›, in this order.
 7. Now let's build our program in stages. We will want ‹main.o›,
    ‹bye.o› and ‹libhello.a›. Then link them all together to form
    ‹a.out›, as usual.
 8. Check that ‹a.out› works as expected.

We can now go back to reading and writing files in C. Let's have a
look:

    $ micro stdio.c
