CS 208: Computer Organization & Architecture

Getting started with C

There are several topics coming up in the second half of this course for which knowing a little bit of the C programming language would be helpful. So today, we're going get you started with C.

A few observations up front

Study some simple C programs

Each of the following programs illustrates a few key concepts in C. Read each program, try to predict what output it will produce, and then compile and execute the program. Talk about the programs, play around with modifying them, etc. You'll need to know how they all work.

Write your own program in C

Any non-trivial program will help you practice your C skills. Here are some ideas you could try.