General Description Requirements Readings Topics Policies Schedule
COMS 1003: Introduction to Computer Science and Programming in C

Introduction to Computer Science and Programming in C

General Information

Instructor: Bert Huang. Office hours Tuesday 2:30 PM - 4:30 CEPSR 624 (or by appointment)
TA: Deergha Sahni, UNI: ds2664, Office hours Wednesday 3:00 PM - 5:00 PM TA Room
TA: Peter Lu, UNI: yl2505, Office hours Thursday 4:00 PM - 6:00 PM TA Room
TA: Sharath Avadoot Gururaj, UNI: sa2617, Office hours Monday 1:30 PM - 3:30 PM TA Room
Time: Tuesday and Thursday 1:10 PM - 2:25 PM
Location: Mudd 834 Changed to Mudd 233
Courseworks site (message board etc.):


From the university bulletin: A general introduction to computer science concepts, algorithmic problem-solving capabilities, and programming skills in C.

In particular, this course will teach algorithmic problem-solving and analysis skills that will be applied specifically to C programming in the Linux environment.




(This list is not in any particular order, nor is it comprehensive. It should however provide an idea of what the course will cover.)

History of C, pseudocode, commenting, code style, basic complexity, Big-O notation, compiling (gcc), abstraction, scope, functions, basic input/output (I/O), conditionals (if, switch, etc), loops (while, for, do), recursion, basic data types (boolean, char, int, long, float, double), complex data types (arrays, enum, structs, unions), memory management, pointers, file I/O, macros, header and src files, basic computer architecture, testing, documentation, debugging, introduction to object-oriented programming, etc.

Course Policies


The course will have four homework assignments distributed throughout the semester. Each will be a combination of programming problems and "pencil-and-paper" computer science problems.

There will be a midterm exam and a final exam. Both will be open book and open notes, since our goal is to teach problem-solving skills, not memorization. Unfortunately, due to the need to avoid communication during the exams, no electronic devices will be allowed.

Finally, students will also be graded on class participation. The final grade will be a weighted sum of the following:

(This breakdown is subject to change, but it should be similar to the percentages listed above.)

Academic Honesty

Please read through the department's policies on academic honesty ( In this course all work is to be done individually.


I will not be keeping attendence but it is in your best interest to come to every class.


If you found an error in grading, please type and print your argument on paper and deliver it to a TA. The TA will respond to your complaint and if there is still a disagreement, repeat the same written-argument process with the instructor (Bert) and he will make a final decision on the disagreement.

Schedule of classes (tentative)

DateTopicLinks and Reading
Tuesday, 9/2/08First class. History of C. Computer Science and ProgrammingPCP Ch. 1 (very short). Slides
Thursday, 9/4/08Computer History and Basic ArchitectureCunix tutorial:, Slides
Tuesday, 9/9/08Linux tutorial. Hello World. Coding style and comments.Homework #1 assigned
Thursday, 9/11/08Variables and Types.PuTTY setup notes. Read PCP Ch. 3 and 4. Slides.
Tuesday, 9/16/08More Types: Arrays, Strings. Command line arguments.Slides. Read PCP Ch. 5
Thursday, 9/18/08Conditionals and LoopsSlides. Read PCP Ch. 6 and 8
Tuesday, 9/23/08FunctionsHomework #1 due. Homework #2 assigned. Slides. Read PCP Ch. 9
Thursday, 9/25/08RecursionSlides. hanoi.c. How to check your tar file
Tuesday, 9/30/08More Types: unions, structs, typedefSlides
Thursday, 10/2/08File I/OSlides. counter.c, reader.c
Tuesday, 10/7/08C PreprocessorSlides. Read PCP Ch. 10
Thursday, 10/9/08Bit Operations and Boolean LogicSlides. Read PCP Ch. 11
Tuesday, 10/14/08C Standard LibrariesSlides. Homework #2 due
Thursday, 10/16/08Midterm ReviewSlides
Tuesday, 10/21/08Midterm ExamHomework #3 assigned.
Thursday, 10/23/08PointersSlides. Read PCP Ch. 13
Tuesday, 10/28/08Memory ManagementSlides
Thursday, 10/30/08Big-O Notation and SortingSlides
Tuesday, 11/4/08No class: Election Day
Thursday, 11/6/08Program Design, Pseudocode, HeadersSlides. count.c,main.c,count.h
Tuesday, 11/11/08Modular Programming (object-oriented thinking), MakefilesHomework #3 due. Homework #4 assigned. Slides. Read PCP Ch. 18
Thursday, 11/13/08Pointers Revisited: FunctionsSlides. TCPL Ch. 5
Tuesday, 11/18/08Basic Data StructuresSlides. PCP Chapter 17
Thursday, 11/20/08Software EngineeringSlides
Tuesday, 11/25/08A look at C++ and JavaSlides
Thursday, 11/27/08No class: Thanksgiving Day
Tuesday, 12/2/08Artificial Intelligence (Free Topic)Slides
Thursday, 12/4/08Last class. Final Review.Homework #4 due. Slides