COMS 1003: Introduction to Computer Programming in C (Fall 2005)

A general introduction to computer science concepts, algorithmic problem-solving capabilities, and programming skills in C.
Michael E. Locasto

[course details] [academic honesty] [syllabus] [web board] [policies] [Courseworks] [academic calendar] [ACM Code of Ethics] [FAQ] [links]

General Information:

Prerequisites: Introductory course requires basic familiarity with a computer. Must know how to type, surf the web, and read email. Will learn fundamentals of the Unix command line and be exposed to the philosophy of algorithmic thinking. Basic familiarity with any programming language is a plus, but not required. No knowledge of C required. Course consists solely of a 3 point lecture, although the homework assignments include programming tasks. A CS cluster account ($50.00 USD fee) is required. Read the FAQs at that page for more information. If this fee represents a significant financial hardship, email me before class starts.

The SSH client PuTTY is useful to access the and machines to do your work remotely from Windows. DO NOT use machines for work. You may use your own Linux machine to complete your assignments, but remember that your packaging must match the specifications in the assignments and that your code must compile and run on the clic machines, as that is where it will be graded.

Name Role UNI Office Hours
Michael Locasto Instructor mel2008 10am - noon :: Tuesday, CSB 522, or by appointment
Bert Huang TA bch2104 2:30pm - 4:30pm :: Monday, TA Room
Eli Alper TA ema2119 11am - 1pm :: Thursday, TA Room
Vipul Bhasin TA vb2139 2:30pm - 4:30pm :: Wednesday, Carleton Lounge

Meetings: Tuesday & Thursday 13:10 -- 14:25, 717 Hamilton Hall. The elevator in Hamilton is quite small, so this class will be a chance to improve your stair climbing skills.

Optional Homework Lab Session: (not required) Monday & Wednesday 19:00 -- 20:00, Thursday 19:30 -- 21:00, CS 486 (CLIC lab). The CLIC lab has been reserved as a convenience for you to accomplish your programming homework directly on the clic machines. Swipe access to CS 486 comes with the CS account. I plan to drop in (as should the TA's) during these time slots for extra help outside of office hours. These times will also play host to the occasional recitation.

Course Texts:


  1. The C Programming Language, Second Edition by Kernighan and Ritchie. (ISBN 0-13-110362-8) [Prentice Hall] [Amazon] (wikipedia entry)
  2. Practical C Programming, Third Edition by Steve Oualline. (ISBN 1-56592-306-5) [Barnes & Noble][Amazon][OReilly]

Supplemental Texts: (not required, but helpful C references)

  1. Mastering Algorithms with C by Kyle Loudon. (ISBN 1-56592-453-3). [Amazon][OReilly][Barnes & Noble]
  2. C How To Program, Fourth Edition by Harvey and Paul Deitel. (ISBN 0-13-142644-3). [Prentice Hall][Barnes & Noble][Amazon]

For the text books, remember that B&N usually offers same day delivery in Manhattan. The Deitel book also covers C++ and Java and is relatively expensive. If you're really interested in learning C and mastering it, then the Loudon book is a good second step. The Oualline book covers much of what Deitel2 covers on C anyway. The K&R book is an absolute must. My aim here is not to make you spend money, but rather list four books that you will be glad are still on your bookshelf in four years.

Lecture Notes and Course Schedule:

Columbia Academic Calendar
Date Topic Assignment(s) Due Notes
September 6 Course Overview    
September 8 no class    
September 13 Bits, Boolean Logic, & Discrete Math [review]  
September 15 Basic C Programming
[hello.c, onerand.c, Makefile] [review]
Assignment 1, Readings (linked off weboard)
September 20 Variables, Primitive Types, Operators, Expressions
[showsize.c, consttest.c, bittest.c, Makefile]
PCP::Chp1 & 4, TCPL::preface x2, intro
September 22 Arrays, Strings, & Command Line Args
[echoargs.c, shoutarg.c, argtest.c, Makefile]
PCP::Chp2, 3 & 5, TCPL::Chp2, 1.2
September 27 Control Flow: Decision & Repetition Statements
[arrayquiz.c, boolexp.c, Makefile]
PCP::Chp 6, 8 & TCPL::Chp3
September 29 Functions & Recursion
[mathline.c, callvalue.c, Makefile]
PCP::Chp 9 & TCPL::Chp4, 1.7, reading
October 4 Functions & Recursion
[fact.c, Makefile]
October 6 Constants, Typedef, and Storage Classes
[typdeftest.c, statictest.c, scopes.c, Makefile]
Homework 1 due, PCP::pg77,177
October 11 Computer History & Basic Organization
[review, more review]
October 13 Complex Data Types
[song.c, advancedata.c, Makefile]
PCP::Chp12 & TCPL::Chp6
October 18 Review for Midterm
October 20 Midterm Exam.    
October 25 Basic I/O Routines
[hi.c, echoin.c, printscores-first.c, printscores-wrong.c, printscores.c, calcscores.c, Makefile]
October 27 File I/O
[cat.c, cat-from-class.c, Makefile]
Homework 2 due  
November 1 Pointers
[pointerstring.c, pointermath.c, basicpointers.c, Makefile ]
PCP::Chp13 & TCPL::Chp5
November 3 Pointers II (Function Pointers, Params)
[functionptr.c, Makefile]
PCP::Chp17, TCPL: 5.11  
November 8 No Class. Election Day. Go Vote.  
November 10 Memory Management
[carorder.c, Makefile]
November 15 Searching    
November 17 Sorting
[sorts.c, hash.c]
TCPL 6.6  
November 22 The C Preprocessor, Header Files, Macros Homework 3 due, PCP::Chp10 & TCPL 4.11, Appendix A.12
November 24 No class. Thanksgiving.    
November 29 Homework 4 Design    
December 1 Standard Library, Operating Systems Overview TCPL::Appendix B
December 6 Program Analysis
[crypto.txt, bigo.c]
December 8 Review    
December 13 Study Day Homework 4 due at 23:59:59  
Tuesday, December 20 Final Exam HAM 717 1:10pm - 4:00pm

Course Policies:

The point of this course is your intellectual enlightenment and enjoyment. I want the course to run as smoothly as possible, so I encourage feedback on both positive and negative aspects. Feel free to drop by my office, send email, or leave a note.

Your grade is based on 1000 points and is split according to the following schedule:

Class participation counts heavily towards your final grade. I expect and encourage thoughtful and lively participation and discussion. I strongly encourage you to use the class web discussion board to communicate with the TAs. This BBoard will most likely NOT be the one provided in Courseworks, because the Courseworks software has many sub-par components. In your professional computing career, you have only to look at certain portions of this system to have an example of how not to do something.

Refrain from posting solutions or questions that encode a solution. DO ask questions that would likely be of help to your classmates. If you have a question, it may have been answered on the board already, so please check before you post a "me too" question.

I typically DO NOT scale or curve grades unless there is a classwide epidemic of failure. Plan your work and effort based on the assumption that there will be no curve.

You can contact me via email, but start your email's subject with the string [COMS1003]; otherwise, I will likely not see it. The TAs are here to help you with coursework. Utilize them. Refrain from emailing me technical questions; instead, use the BBoard, as I monitor it frequently. You should save direct emails for personal discussions (your grade, etc.). You can encrypt your email to me if you wish, using my GPG (GNU Privacy Guard) public key. Keep your email short and to the point. I'll probably ignore it if it is longer than one or two paragraphs.

Please turn off all cell phones, pagers, and other noise-making devices. If you prefer to come to class with your iPod and watch me blather on to your personal soundtrack, that's fine, just make sure your neighbors can't hear it.

There may be unannounced quizzes. They will count toward your class participation and cannot be made up.

While collaboration on homework and projects is greatly encouraged, your answers must be original. No collaboration is allowed on the final or midterm. Students collaborating on assignments must clearly list with whom they worked. If your answers look the same or I feel that one person did the work and the other copied, I will toss a coin. If the coin comes up heads, both parties will get a zero. If the coin comes up tails, you will both split the credit for the question. The bottom line is that general discussion is welcome, but specific solutions cross the line.

Cheating and Plagiarism are absolutely forbidden. I will assume that you have read both the Computer Science Department's Policies and Procedures Regarding Academic Honesty and Columbia's Engineering School general Policy on Conduct. Retribution and penance are swift and severe. Again, I urge you to read the policies for your own good. It is almost absurdly easy to discover cheating, and often difficult enough to do a good job camouflaging the cheating that you would have saved time just doing the assignment.

No late work will be accepted under any circumstances.

Grievence procedures: If you feel that grading was unfair, you must follow this procedure in order to document your case and bring it to a swift and fair conclusion. The policy is meant to give you a fair shake without wasting the TA or professor's time. This is a classic tradeoff; computer science is all about tradeoffs.

  1. When your work is returned to you, check it.
  2. Do NOT make an immediate verbal complaint to the professor or TA. Such complaints will be ignored or forgotten. Instead, see point 3.
  3. Document in writing what you think is the grading mistake. Writing does not include email. "Writing" means hard copy printouts of typed material.
  4. Submit your written complaint to the TA. Keep a copy for yourself.
  5. The TA will respond in writing. The TA will keep a copy for himself.
  6. If the matter is not resolved by the TA, you may submit the written record of the dispute to the professor.
  7. The professor will examine the written record only and decide the merit of the matter. The professor's word is final.
Hints and provisos:
  1. Be terse. Good writing does not waste words. Eloquence is not indicated by complex and flowery phrases.
  2. The right to regrade the entire assignment is reserved.
  3. If you have a complaint, you should initiate this procedure no later than one week from the time the work was returned (or made available) to you, regardless of whether you were in class or not.
  4. Don't try to justify a clearly wrong answer. Argue only for what are clear mistakes in grading or where you believe the official answer is flawed or wrong. If your argument has merit, it will succeed.
  5. Avoid ad hominem attacks. Stick to the facts.

last updated: 6 December 2005
Copyright © Michael E. Locasto 2005 .