
C Structures Worksheet
Do these problems in sequence as each builds on the previous.
1. Declare a structure called a Wombat that contains a float f, a
long integer L, and a pointer to another Wombat called Next. It
should also contain a 20 character array called Name.
2. Declare a Wombat called Ralph. Declare an array of Wombats
called Munroe with 10 members.
3. For problem 2, write the code to set Ralph’s float to 13.7 and
his name field to “The Doctor”.
4. Declare a ten element linked list of Wombats. Make sure that
you link them together.
5. Declare a pointer to a Wombat. Write the code to set it to
point to the 0th Munroe of problem 2, and set the f field to
17.1. Also, set the name to “Burgermeister”.
6. Write function to print out all of the Name fields for the
list of problem 4.
ET283 Worksheet: C Structures 1