Ryerson University
Department of Computer Science

CPS125 – Digital Computation and Programming
Course Outline and Course Management Form (Winter 2008)

Professors

Dr. Chen (Cherie) Ding
Office: ENG258
cding@cs.ryerson.ca

Dr. Denis Hamelin
Office: ENG276
dhamelin@cs.ryerson.ca

Dr. Joshua Panar
Office: ENG259

jpanar@cs.ryerson.ca

Dr. Abdul N. Shaikh
Office: ENG274

anshaikh@cs.ryerson.ca

Course Description:
Digital Computation and Programming. The C programming language is used to develop good programming techniques. Topics covered include: C program form, language statements, pseudo-code algorithmic representation, numeric data types, flow of control with selection and repetition, standard C libraries, functions and call modes, arrays, pointers, sorting, matrix operations, character and string data types, dynamic storage, structures and linked lists, file I/O. Only regular first year students from the Faculty of Engineering and Applied Science may preregister for this course.

Course Format:
3 weekly lecture hours and 2 weekly lab hours.

Course Websites:
The official course website (
www.living-net.org/cps125) and your professor's website for specific section information. (must be consulted at least once a week) .

Course Texts:
•Tan, H. H. & D'Orazio, T. B. (1999),
C Programming for Engineering & Computer Science, New York: McGraw-Hill. (reference course text)
•Hanly, J. R. & Koffman, E. B. (2008),
Problem Solving and Program Design in C – Custom Supplement for Ryerson University, Boston: Pearson Custom Publishing. (exercises book) [highly recommended]
•CPS125 Lab Manual (http://www.cs.ryerson.ca/dhamelin/cps125/labs/manual.html). Available in the course web site's Bookcase section.

Optional lab references:
•Academic Computing Services (2004),
User's Guide to Academic Computing and the Internet, Toronto: Ryerson University Bookstore. Also available on line
•If your lab uses the facilities of the Department of Computer Science (ENG Building), you will need this reference instead.

Schedule of activities

(the material will not necessarily be covered in the exact order given)

Week #

Contents

Format

Readings

Things to do

1

Course introduction. Computer and computing fundamentals: History of computing, computer architecture, networks, software engineering, programming languages.

Lecture

Chapter 1

NO LAB THIS WEEK

2

Introduction to C: Basic structure, comments, formatting output, escape sequences, debugging.

Lecture

Chapter 2

NO LAB THIS WEEK (Except Friday Labs)

3

Variables, arithmetic operations, math functions and I/O: Identifier names, constant macros, arithmetic operators and expressions, evaluating expressions, type casting, reading data from the keyboard, reading data from a file, math functions, writing output to a file.

Lecture
Lab

Chapter 3
(3.1 to 3.8)

LABS START ON JAN. 18, 2008
LAB #1

4

Decision Making (Selection): Logical expressions, if statement, switch statement.

Lecture
Lab

Chapter 4
(4.1 to 4.6)

LAB #2
Term Test #1 (Jan. 29)

5

Loops I: Theoretical kinds of loops (counting loops, sentinel loops, EOF loops, input validation loops, general loops). C statements implementing counting loops.

Lecture
Lab

Chapter 4
(4.7 to 4.8)

LAB #3
Assignment #1 available

6

Loops II: C statements implementing advanced loops. Nested loops. Practical applications.

Lecture
Lab

Chapter 4
(4.9 to 4.11)

LAB #4

7

Functions I: Concepts. Defining functions. Calling functions. Scope of names. Function with value arguments (no arguments/no result, 1 argument/no result, 2 or more arguments/no result, no arguments/1 result, 1 argument/1 result, 2 or more arguments/1 result). Number-Order-Types of arguments/parameters pairs. Case studies.

Lecture
Lab

Chapter 5
(5.1 to 5.3)

LAB #5

8

Functions II: Pointers. Using pointer parameters to simulate multiple results from a function. Recursion.

Lecture
Lab

Chapter 5
(5.4 to 5.5)

LAB #6
Assignment #1 due

9

Arrays I: Numerical arrays of one dimension. Passing such arrays to functions (pointers and arrays). Dynamic allocation of 1D numerical arrays.

Lecture
Lab

Chapter 6
(6.1 to 6.3, 6.5)
7.10 (calloc only)

LAB #7
Assignment #2 available
Term Test #2 (Mar. 7)

10

Arrays II: Strings. Passing strings to functions (pointers and arrays). Dynamic allocation of strings. String functions (string.h). Character functions (ctype.h). Arrays of strings (Introduction to 2D arrays).

Lecture
Lab

Chapter 7
(7.1 to 7.8)

LAB #8

11

Arrays III: Multidimensional arrays. Passing such arrays to functions (pointers and arrays). Dynamic allocation of 2D arrays.

Lecture
Lab

Chapter 6
(6.4, 6.6)

LAB #9

12

Structures: The typedef construct. Operations on structures. Structures and functions. Pointers on structures (arrow operator).

Lecture
Lab

Chapter 8
(8.1 to 8.5)

LAB #10
Assignment #2 due

13

Command-line arguments and I/O redirection. Review of redirection vs. File I/O (advantages and drawbacks). Course review. Review exercises.

Lecture

Chapter 8
(8.21*)
*available on-line

NO LAB THIS WEEK

 

 

 

 

 


Evaluation:

Tests and exams (85%)

Term Test #1 (15%)
Term Test #2 (35%)
Final Examination (35%)

Labs and assignments (15%)

Labs (5%)
Assignment #1 (5%)
Assignment #2 (5%)

Important notice: In order to pass the course, it is necessary to obtain 50% of the tests and examination marks *and* 50% of the total marks. In other words, your labs and assignments will *not* count if you don't have the required minimum 50% (42.5/85) on tests and exams.

General Information:
The term tests and final exam will consist mainly of writing C functions and programs. There may also be questions related to specifying the exact output produced by the execution of a given program, finding errors in a program or filling the blanks in an incomplete program.
All tests must be written in pen, not pencil.

The labs will be graded based upon attendance and your complete devoted attention to the activities specified in the lab manual. Attendance for the *entire* lab period is required to avoid being marked absent. Also, engaging in any activity other than the one prescribed in the lab manual will give you an absentee status (a zero mark) for that lab. Again, lab attendance and work is *mandatory*. If you get three or more labs with a zero mark (unless you are absent with a valid reason (approved by FYCEO), you will get an F grade.

Assignments consist of designing, writing and testing a program to solve a given problem. Assignments and labs are to be done individually, and are marked based on correctness of results, quality of documentation, style and layout. Assignments and lab programs must contain the following comment: /* This program is my own individual work */. Copied work (both copy and original) will be given a grade of zero. Involvement with plagiarism can ultimately result in course failure and/or expulsion from the University in accordance with the Ryerson Student Conduct Code. If you are found guilty of academic misconduct the minimum penalty you will receive is a mark of zero on the test, exam, paper, project or assignment in question and the notation “Disciplinary Notice (DN)” will be placed on your academic record and official transcript where it will remain for eight years.

Late assignments will not be accepted for marking. Assignments must be submitted in the format detailed in class, and are to be submitted as directed by your Professor. Assignments submitted in any other fashion are deemed void.

It is important that to know your CPS125 section number. Marks will be lost on any evaluation missing proper identification, i.e. Family/Last Name, Given/First Name, Section Number and Student Identification (only if specifically requested).

Again, a reminder that in order to pass the course, it is necessary to obtain 50% of the (tests + examination) marks and 50% of the total marks and having attended 8 labs or more.

Students are responsible for logging on to the course website at least weekly, and for following all course related instructions so transmitted.
Students should also check their email daily for any notices from the Professors and are responsible for following any directives so sent.

As course topics typically develop based on material from previous lectures, students are strongly urged to attend ALL classes. If you miss any material due to illness or other unavoidable circumstance be sure to catch up before the next class.

Grades on assignments, tests and labs will be available on the Blackboard/RAMSS system or other means specified by your Professor. As per Ryerson regulation, final exam marks and grades will be disclosed only by the registrar's office.

A faculty course survey will be filled by the students during week 11.

Rules and regulations:
The rules and regulations are for the enjoyment and respect of everyone in the class including yourself. Thank you very much for abiding by them:

Please refrain of talking during the lecture. Everybody needs to hear correctly. If you feel the urge to talk, you are invited to step out of the classroom.

Please shut down you cell phone or put it in vibrating mode during the lecture. If you are expecting an important call, and do not have a vibrating function, please answer it immediately and step out of the classroom to talk.

Please arrive on time, class will promptly begin at :10. If you arrive late or have to leave early, please do so quietly and be nice and close the door behind you if it doesn't close automatically.

Please be reminded that the Teaching Assistants (TAs) have the authority of the Professor in the lab sessions. You are to treat the TAs with respect.

Emails to your Professor should always begin with a greeting (Dear Dr. X, Dear Professor Y) and be written in proper English (no chat room lingo please). Your should also always indicate your name (family, given in that order), course (CPS125) and section number in all communications. You must always use your ryerson.ca email to communicate with your Professor. Messages sent from other addresses (gmail, hotmail, ...) most likely will not be answered.

Changes:
Modifications to the course procedures will be made in consultation with the students and will be announced on the course website.

Note: Sections in purple are new for 2008