CMSC 106 Introduction to C Programming Spring 2003

1 Instructors

Sections 020X and 060X Sections 030X, 040X, and 050X
Brian Postow Steve Scolnik
3223 A. V. Williams, 405-6713 3211 A. V. Williams, 405-2692
bpostow@cs.umd.edu1 steves@cs.umd.edu1

 


2 Prerequisites and description

Corequisite (or prerequisite): MATH 140 and permission of department. Not open to students who have completed CMSC 114 or higher. Design and analysis of programs in C. An introduction to computing using structured programming concepts. CMPS and Computer Engineering majors will be given priority for registration until the first day of classes.

3 Overview

CMSC 106 is an introduction to computing and program development in the C programming language. This includes a brief introduction to basic computer concepts, an understanding of the UNIX operating system sufficient for writing class programming assignments, thoroughly studying the syntax and semantics of the basic control structures of C, learning C's fundamental data types and structures, understanding the design and methodical construction of computer programs, learning how to test and debug programs, and, lastly, practice in all of these through creating several programs in C. The major topics covered by week can be found in the chart in the last section of this syllabus.

Computer programming is by its nature inherently mathematical and logical; learning a programming language is challenging and difficult, and is hard work for most students. This is especially true of the later programming assignments to be implemented in CMSC 106. However, the only way to fully learn programming language concepts is to use them, by writing programs. For this reason, students who do not complete the assigned programming projects will be very unlikely to perform at even a minimum adequate level on the exams.

4 Teaching assistants and undergraduate teaching assistants

Some of the teaching assistants will conduct discussion sections, some will grade projects, and all will hold office hours on a walk-in basis for tutoring and questions about the course material, as well as assistance with the programming projects, in 1151 A. V. Williams.

See the separate handout for teaching assistant names and office hours.


5 Office hours and email contact

The instructor and TA office hours will be provided in lecture and available in the class posting accounts and on the class webpage (see below).

Our email addresses are supplied so you can contact us when absolutely necessary in emergency situations, but we regret that due to the large size of this course we have insufficient resources to conduct routine course business via email. We strive to answer email in as timely a fashion as possible but there is no guarantee how quickly that might be at any particular time. We can not under any circumstances debug students' projects via email. We will generally be unable to answer any substantive questions on course material via email; these are more appropriate for class discussion or office hours. Personal communication, in office hours or before or after class (if time permits), is the preferred means of communicating with us and the quickest way to receive a reply. We will always be able to devote more attention and to give a much more detailed reply to any issue which is discussed in person.

6 Textbook

Text:
C Programming: A Modern Approach, K. N. King, W. W. Norton, 1996.

7 Posting accounts and class webpage

Various course materials will be made available on the class webpage, or in the course posting accounts (to be explained further in discussion section). Important announcements will also be made through both the posting accounts and the webpage; students are responsible for reading these announcements frequently and knowing their contents. The posting account for Brian's sections (020X, 060X) is bp106001; the posting account for Steve's sections (030X, 040X, 050X) is ss106001. The class webpage is at the following URL:

http://www.cs.umd.edu/class/spring2003/cmsc106/.

Directions for obtaining course materials in the posting accounts and reading the announcements will be provided in class.

Do not send any email to the posting accounts; it will not be read. Only use the email addresses listed above as specified in the section "Office hours and email contact."

8 Course requirements and grading policies

Although attendance will not be taken, students are required to attend all classes. In particular, students will be held responsible for all material covered and announcements, policies, and deadlines discussed in lecture and discussion section, regardless of whether they were in class to hear the information or not.

Homework exercises and solutions will be made available in the course posting accounts; these will not be collected or graded, but serve as practice for you to test your knowledge of the material, and as preparation for exams, quizzes, and projects. You should read the relevant chapters and solve the homework exercises when topics are first presented in lecture to insure you are prepared when it is time to write the programming assignment requiring this material.

Quizzes will be given during the discussion or lab section. You will receive no credit if you take a quiz in the wrong discussion section. In particular, if your assigned section meets at 2:00 p.m. and you wait until the 3:00 p.m. section to take a quiz, or take it in any other section, you will receive a zero. This is to prevent overcrowding of discussion sections.

Coursework will count towards the final grade according to the following percentages:

Quizzes: weekly quizzes, on reading, lecture, and discussion material 10%
Programming projects: seven coding assignments 30%
Midterms: two midterms 30% (15% each)
Final: (will be comprehensive) 30%

Any request for reconsideration of the grading on any exam, quiz, or project must be submitted to your TA or instructor within one week of the original return date of the exam, quiz, or project, or it will not be considered. The instructors reserve the right to regrade the entirety of any exam, quiz, or project so submitted, which could result in a lower score for coursework submitted for specious reasons.

8.1 Quizzes

Quizzes will be held every week on Monday during recitation (unless there is an exam scheduled on that Monday). They will cover material from the previous week. They are intended to be fairly easy and determine whether you understand the material just presented. They will NOT be representative of the midterms or final.

9 Project submission and grading policies

NOTE: assistance with and suggestions regarding project problems are provided during office hours, but it is the responsibility of the student to develop and to do most of the debugging of his or her own program. Do not expect the TAs or instructors to take the primary responsibility for getting your project to work.

Projects will be submitted electronically and further instructions will appear on the assignments and be covered in discussion section. Under no circumstances will any emailed project, or any attempt to submit a project using any means other than that specified on the assignment, be considered.

All projects will be due at 11:00 PM on the day indicated on the project assignment. A project will be accepted up to two days late with a 15% deduction in credit for the first day and an additional 10% deduction for the second day. All projects will be graded out of 100 points, but as the semester progresses they will increase in difficulty, and consequently count more towards the final grade. Of the projects' 30% contribution to the course grade, they will individually be apportioned credit as follows:

Project #0 2%   Project #1 5%   Project #2 13%   Project #3 13%
Project #4 15%   Project #5 15%   Project #6 17%   Project #7 20%

Projects will be graded as follows. All projects will be run on a primary input data set which will be made available with each project assignment (except for Project #0). The program's results when run on the primary input will also be given as the primary output. There will also be other sample input/output sets provided for most projects. These will not be used in the grading process; they are only to provide more samples for testing of your project. For grading, projects will also be run on various secondary inputs which will not be provided in advance. A submitted project is considered to satisfy the primary output if all the data values in its output, when run on the primary input, exactly match the data values in the corresponding primary output.



Projects not submitted by the end of the two-day grace period will not receive any credit. Since there is therefore no reason to submit a project after its two-day late period is over, projects submitted after that time will not be graded. As described above, all projects submitted will receive at least some partial credit, even those which do not produce correct results, so it is advisable to submit something for each project, even if it is incorrect or incomplete.

If more than one submission has been made by a student for any project assignment (for example, both an on-time submission as well as a two-day late submission) all submissions will be graded and the highest grade will be recorded.

Due to the numerous issues regarding incompatibility between compilers, operating systems, file formats, etc., on different computer systems, students are strongly advised to do all of their program development on the OIT UNIX Class Cluster. All students registered will be issued class accounts on these systems.

If you have access to another computer with a C compiler, such as a personal computer at home or another computer system at your job, and you choose to work on your programming projects there, you should keep the following information in mind. All project submissions must be made from your class account on the OIT Class Cluster and must run and work correctly using the ``cc'' compiler available on the class cluster, with the ``-std1'' and ``-trapuv'' options. If the program you submit does not compile on the class cluster using this compiler and options, you will receive at most 40 points for it as described above, regardless of whether you had a working version on some other computer at some earlier time. The instructional staff only has access to your class account in office hours, and cannot help you with any program written on any other computer (except from a printout). Furthermore, it is your responsibility to find out how to transfer a program to your class account for submission; the instructional staff cannot help with this (see the Help Desk in 1400 CSS for information on transferring files between computers, or check their webpage at http://helpdesk.umd.edu). No consideration will be made in grading for any errors made in transferring files, or mistakes involving transferring the wrong file from some other system to your class account. Due to implementation-dependent behavior permitted by the language standard, often a program will work perfectly when compiled with one compiler or on one system, yet not work at all when compiled with another or elsewhere. If you still want to attempt writing any project on another system you are strongly recommended to complete it several days early, to have time to address any problems arising from transferring files or any problems related to compiler incompatibilities.

10 Late policies and other special policies

Students with disabilities who have been certified by Disability Support Services as needing any type of special accommodations should see their instructor as soon as possible.

It is the University's policy to provide reasonable accommodations for students observing religious holidays, but it is the student's responsibility to inform the instructor in advance of any intended religious observances. Written notice must be provided no later than the end of the schedule adjustment period for any accommodation to be made.

Excused absences for quizzes or exams, or extensions on projects (as discussed below), will be approved only with proper documentation. If you have a valid reason for missing an exam or quiz or requesting an extension on a project, it is your responsibility to have the proper verification. A medical excuse consists of written verification from the Health Center, or a letter from your personal physician stating that you were incapacitated and listing exact dates of incapacitation. This written verification must include the telephone number of a contact person. A ``Verification of Visit'' form from the Health Center will not be accepted - you must instead have a ``Class Excuse Form'' in which a medical practitioner specifically writes your dates of incapacitation, otherwise the excuse will not be accepted. You may have to sign a release at the Health Center in order to get a Class Excuse Form. Note that an illness is considered severe enough to warrant an excused absence or extension only if a medical doctor states that you were incapacitated by it. According to this policy, unless you were ill enough to require medical care, you can not receive an excused absence or extension; staying at home during an illness, regardless of severity, does not constitute a valid medical excuse. Furthermore, in the case of missed exams or quizzes the date of an illness as listed on the documentation must include the date of the exam or quiz; being ill some time before the exam or quiz but not on its exact date will not count for an excused absence. Medical documentation which does not provide the information described will be rejected, and as a result an excused absence or extension will not be granted. If you will be missing an exam or quiz for any reason other than medical (e.g., a job interview or required University function), you must contact your instructor at least one (1) week in advance to request consideration of your circumstances.

There will be no make-ups for missed quizzes. With a documented medical excuse or in the case of a documented family or personal emergency (such as a serious automobile accident or close relative's funeral) a missed exam or quiz grade will be calculated by averaging your scores for the other exams or quizzes.

As discussed above, projects may be submitted without any special permission up to two days late, with a deduction in credit for each day, up to a total deduction of 25%. Projects will be assigned with more than sufficient time to be completed by students who have a reasonable understanding of the necessary material and begin promptly. As a result, extensions on project assignments will be granted only in extreme circumstances, and will only be of short duration even in such cases, possibly much less than the number of days missed. In the case of serious illness, accident, or family or personal emergency, an extension on a project will be considered if your instructor is notified in advance of the due date, either in person, by email, or by telephone. Only in cases of illness or emergency so serious that advance notice is impossible, such as in cases of extended, major illness, or serious accident or emergency, with documentation to that effect as described above, will an extension be considered without advance approval. In such cases it is your responsibility to notify your instructor as promptly as possible, otherwise an excused absence will not be granted. Unless your instructor was notified of any extenuating circumstances before a project assignment has been graded and returned, no extension will be considered under any circumstances, even with proper documentation.

11 Exam and quiz dates

Quizzes will be held every Monday. You may not assume that they will be announced in lecture, in the class announcements or on the class webpage.

Exams will be held on the dates below, unless a change is necessary to accommodate lecture topics. In that case, the revised date will be announced in lecture and posted in the class announcements and on the class webpage. The final exam date, however, is fixed. Students' final exams will be rescheduled only due to their having another course's final at exactly the same time as this course's. If you have such a conflict with another final, it is your obligation to inform your instructor at least one month before the time of the final exam, otherwise no allowances can be made. The midterm exams will be held in the discussion section time, but in a different location, to be announced in lecture prior to the exam dates.

Exam Date Location
Exam #1 Monday, March 10 TBA
Exam #2 Wednesday, April 9 TBA
Final exam Saturday, May 17, 4:00-6:00 TBA

12 Academic honesty statement

Please carefully read and consider the Computer Science Department policy regarding the use of computer systems, and the Office of Information Technology's policy regarding acceptable use of computer accounts provided for instructional use, in the Fall 2002 issue of the departmental newsletter, CS Tid-Bits. Note in particular the penalties for impermissible cooperation on programming projects, which is a violation of the University's Code of Academic Integrity. Any evidence of unacceptable use of computer accounts or unauthorized cooperation on exams, quizzes, or projects will be submitted to the Student Honor Council, without notification or warning, which could result in an XF for the course, suspension, or expulsion from the University.

NOTE SPECIFICALLY that projects are to be done INDIVIDUALLY. For academic honesty purposes, projects are to be considered comparable to an extended take-home exam. That is, any cooperation or exchange of ideas which would be prohibited on an exam is also prohibited on a project assignment. Working IN ANY WAY with another student or individual will be considered a violation and WILL BE REPORTED to the Honor Council. Students may not discuss design of an entire program or of parts thereof, or any high-level code with anyone except the instructors and teaching assistants. Students may use any published textbooks, but any information which is not a student's original work must cite the source of that particular information in a comment in that section of the program. If you have any question about a particular situation or source then consult with your instructor. Should you have difficulty with a programming assignment you should see the teaching assistants or your instructor in office hours, NOT solicit help from anyone else in violation of these rules. Students are welcome to study together or to receive help in learning the course concepts from anyone else, but other than help from the instructional staff, project assignments themselves are to be solely and entirely each student's own work.


VIOLATIONS OF ACADEMIC HONESTY INCLUDE:


  1. failing to do all or any of the work on a project by yourself, other than assistance from the instructional staff.

  2. using any ideas or any part of another student's project, or copying any other individual's work in any way.

  3. giving any parts or ideas from your project, including test data, to another student.

  4. having programs on an open account or on a PC that other students can access.

  5. transferring any part of a project to or from another student or individual by any means, electronic or otherwise.


IT IS THE RESPONSIBILITY, UNDER THE UNIVERSITY'S HONOR POLICY, OF ANY STUDENT WHO LEARNS OF AN INCIDENT OF ACADEMIC DISHONESTY TO REPORT IT TO THEIR INSTRUCTOR.


Every semester we have taught we have caught students attempting to cheat on project assignments, in violation of the above rules. Every project submitted is checked for violations of the above requirements. Students' academic careers have been ruined by their decision to cheat. Think about whether you want to join them before contemplating cheating, or before helping a friend to cheat.

13 Course topics (SUBJECT TO CHANGE)

This list may vary according to the pace of lecture topics. Not all sections from each chapter will be covered.



Week Topics Chapters
Jan. 26 Introduction, overview of computer systems, basic program structures  
  Syntax vs. semantics, elements of a C program, input and output, UNIX introduction and basic UNIX commands  
  Project #0 assigned this week 2, 3
Feb. 2 Expressions and operators, assignment operators  
  Project #1 assigned this week 4
Feb. 9 Unary increment and decrement operators, program editing and compilation, conditional statements  
  Project #0 due this week, Project #2 assigned this week 4, 5
Feb. 16 Conditional statements (continued), repetition statements 5, 6
  Project #1 due this week  
Feb. 23 Repetition statements (continued), basic types, type conversions, character type and character input 6
  Project #2 due this week, Project #3 assigned this week  
Mar. 2 Arrays, algorithms, pseudocode and programs 7, 8
Mar. 9 Functions, functions and arrays, call-by-value vs. call-by-reference 9
  Project #3 due this week, Project #4 assigned this week  
  Exam #1 (Monday, Mar. 10, in the discussion section time)  
Mar. 16 Function prototypes, local and global variables, blocks, scope, pointers 10, 11
Mar. 23 Spring Break  
Mar. 30 using pointers for call-by-reference, arrays and pointers, pointer arithmetic 12
  Project #4 due this week, Project #5 assigned this week  
Apr. 6 Character arrays and properties, the character and string library functions 13, sections 23.4-23.5
  Exam #2 (Wednesday, Apr. 9, in the discussion section time)  
Apr. 13 String library functions (continued), structures 16
  Project #5 due this week, Project #6 assigned this week  
Apr. 20 Arrays of structures, structures as parameters and return values of functions 16
  Project #6 due this week, Project #7 assigned this week  
Apr. 27 Passing structures to functions using call-by-reference, the preprocessor, separate compilation 16, 14, sections 15.1-15.3

May 4

Storage classes sections 18.1-18.3
  Project #7 due this week  
May. 11 Other topics lecture


Footnotes

1 Please read Section 5 of this syllabus before sending email to any of the instructional staff for any reason.


Steve Scolnik 2003-01-25