C / C++ PROGRAMMING
CIS54 Course Outline - Spring 2011

INSTRUCTOR: Dan McElroy       
OFFICE:
T-410
See the last page of the Syllabus for office hours or http://unix.sjcc.edu/OfficeHours.htm
PHONE:
298-2181 x 3235             
E-MAIL: Dan.McElroy@sjcc.edu


TEXTBOOKS (Optional):
C++ How to Program 7th  Edition,     by Deitel & Deitel - Prentice Hall,     ISBN:0-13-611726-0

COURSE OVERVIEW AND OBJECTIVES:
C is a general-purpose programming language which features economy of expression, modern control flow and data structures, and a rich set of operators. C++ is an object oriented programming language that is built using the C language as a base. The course will explore these features through a variety of programming assignments. This course is for students and professional programmers whose needs include applications packages and/or systems software in software environments where efficiency and portability are important.

This course covers programming using C and C++. Upon completion of this course, the student will be able to:

  1. Demonstrate the ability to read and understand verbal and symbolic statements and translate these into working computer models.
  2. Construct a simple working C or C++ program using the correct structure of the language
  3. Identify valid names for constants and variables. List the C / C++ data types and their attributes. Compare and contrast the differences between data types. Create programs that assign appropriate data types based on a problem definition.
  4. Construct programs that use scanf( ) and printf( ) for input and output in a C program. Construct programs that use cin and cout for input and output in a C++ program. Compare and contrast the advantages and disadvantages of each method. Apply redirection to console programs to modify the source and destination of data.
  5. Describe the operation of each arithmetic, relational, and logical operator. Construct truth tables for simple and complex formulas containing multiple logical operators. Calculate the result of variables when use pre- and post- increments and decrements. Compute the resultant modifications to data when the data is converted from one data type to another.
  6. Describe how arithmetic and logical operators can be combined with the assignment operator to form new operators. Construct expressions utilizing the assignment operators. List the order of precedence for evaluating expressions. Evaluate expressions utilizing expressions having multiple levels of precedence with and without parentheses.
  7. Formulate solutions to simple and complex programming problems using combinations of logical operators as conditional expressions as part of if, elseif, and else statements. Convert if/elseif sequence of statements to switch statements. Compare and contrast the different organizations of code when implemented as if/elseif statements vs. case statements.
  8. Create programs that contain loop structures. Select the appropriate while or do-while structure for a given problem. Compare the use of a for statement to a while statement when used in counting loops. Construct solutions using priming reads and sentinel values when the amount of data is unknown.
  9. Organize a solution to a large program by breaking the program into smaller parts. Describe how data can be passed to and from functions and procedures using argument lists. Describe how functions return integer and non-integer variables. Compare and contrast the use of external variables to variables passed as arguments. Identify the scope and visibility of variables internal and external to a function. Explain the rules of static variables as applied to variables internal and external to a function. Compare and contrast the use of register variables to automatic variables. Demonstrate the use of functions as programming blocks.
  10. Organize data into single and multidimensional arrays. Use index notation to initialize and access data. Diagram and use pointers to access data in arrays. Use an array of pointers to functions to select a function to be activated.
  11. Define how strings are constructed in C and C++. Utilize string library functions to manipulate strings.
  12. Organize different data types into a record using the struct statement. Create arrays of structures. Access data in arrays of structures. Diagram the use of pointers to structures and their data members. Compare and contrast the use of pointers to indexing when accessing data in arrays of structures. Create and utilize pointers to functions. Utilize unions and typedefs statements to create multiple methods of accessing data and new data types.
  13. Define an object-oriented class. Create objects as instances of a class. Create and utilize member constructor and destructor functions. Compare the use of the constructors and destructors to functions external to the class definition. Create arrays of objects and access the objects utilizing index and pointer notation. Describe how the assignment and copy constructors are implemented in C++. Demonstrate the use of the "this" pointer.

----------------------------- LAB CONTENT ----------------------------------

  1. Construct a working program in C / C++
  2. Compare and contrast different data types
  3. Create interactive programs utilizing console input and console output
  4. Develop programs that demonstrate the use of the arithmetic and arithmetic-assignment operators
  5. Implement decision statements utilizing relational and logical operators
  6. Create programs that use sentinel values to terminate data input
  7. Create programs that use a counting value to implement a loop
  8. Divide programs into smaller segments by use of functions and sub procedures
  9. Organize and process data using arrays
  10. Access data through the use of pointers
  11. Manipulate character strings
  12. Write code utilizing Object Oriented Programming (OOP) techniques
  13. Create more complex objects utilizing class functions

MOODLE:
Moodle may contain class notes, PowerPoint slides, class announcements, the course syllabus, test dates, and other information for the course. Lab assignments and homework must be submitted using Moodle. The assignments must have your name, student ID, and exercise name at the top of the document. Late assignments will be accepted with a penalty. Make sure you can login to your Moodle account the first week of class. If you are adding the class, your Moodle account should be active within two hours of your completed add request. Supplementary information for the course on Moodle.

E-MAIL:
All students are required to obtain an e-mail account in addition to their Moodle account. All correspondence through Moodle uses the e-mail address that you have listed with the Admissions and Records office. This includes any messages that I send to the class as well as scores for each assignment. It is important that you update your e-mail address if it changes.
If you have any questions about the course or need assistance, please contact me in person or by telephone during office hours or by e-mail at any time. You can update your e-mail address by clicking the "CLICK HERE" message on the purple rectangle when you go to the MyWeb page at https://myweb.sjeccd.edu (NOTE the 'S' in https, and the 'E' in sjeccd). If you have an e-mail filter for spam, etc., it is your responsibility to make sure that you are receiving the e-mails that I send you, either from my college address Dan.McElroy@sjcc.edu, or e-mails sent through Moodle.

ACCESS TO CAMPUS COMPUTER LABS:
San Jose City College has many computer labs on campus. The labs used by the CIS and CA departments have all of the software installed that you will need to complete the class assignments. Most of the other labs on campus will have Microsoft Office installed, but may not have a C/C++ compiler installed. You need to be an SJCC registered student to use the computers in the Library. You may need to be registered for tutoring to use the LRC labs. Other labs serve different departments on campus. You may need to be registered in one of their classes to use their labs.

LAB ASSIGNMENTS:
Some of the lab assignments will take longer than the time available during class. It is expected that each student will make use of the Open-Lab time to complete assignments as needed. Open-Lab hours are made available to students registered in CIS courses. Instructions will be given during the first class meeting on how to use the open lab.

Programs turned in must include printouts of both the program and the results of testing the program. Some labs may require that a disk be turned in as part of the assignment. Programs will be graded on whether they work, quality of output, program readability and appearance, program construction and completeness of testing, and very importantly - documentation.

LAB ASSIGNMENTS MUST INCLUDE:
1. Your name
2. Printouts of C/C++ code
3. The results of running the lab when available
4. A written description of the lab project in English

ATTENDANCE:
You are expected to attend all class meetings. If you are absent from either lecture or lab, it is your responsibility to find out what you missed, and complete any assignments that were given. It would be a good idea to make a friend or two with other people in the class to share notes in the event that any of you are absent. Once you have shown some commitment to the class by attending, participating in quizzes, labs, or homework, I assume that you wish to be in the class. It is your responsibility to drop the class if you do not wish to continue. However, you may be dropped by the instructor if it appears that you are not participating in the class by submitting regular course work. If you do not complete the course, and do not officially drop through the Admissions office and are not dropped by the instructor, you will receive a grade based on your completed work.

In other words, if you want to stay in the class, you need to submit work on a regular basis or your may be dropped. If you want to drop the class, you should drop the class by one of the drop dates to make sure it happens for the best result on your transcript.

GRADING:

Homework

150 points

 

 DEFINITIONS    
A=Distinguished
B=Above Average
C=Average
D=Minimum Passing
F=Failing

GRADE Points  Percent
 A = 486-540  90%-100%
 B = 432-485  80%-89.9%
 C = 378-431  70%-79.9%
 D = 324-377  60%-69.9%
 F =   0-323   0%-59.9%

Lab work

310 points

 

Final Exam

 80 points

 

Total

540 points

 

   

 


NO-NAME and LATE PENALTIES:
You must include your name, student ID or Moodle ID, and exercise name on all work you submit. Unless otherwise specified in an assignment, your name, ID and exercise name should appear in the upper right corner of your lab report or essay. Penalties will be applied AFTER the score for your assignment has been computed. A maximum of 50% penalty be applied for No-name or Late penalties. No work will be accepted after the Friday following the final exam.

Penalty
Cause
1 point
No name on submitted assignment
1 point
No ID on the submitted assignment. Moodle or SJCC student ID is acceptable.
1 point
No assignment name on the submitted assignment
1 point
Student name, ID or assignment name is hand written instead of typed
-10%
Assignment is one, two, or three days late
-25%
Assignment is four, five, or six days late
-50%
Assignment is one or more weeks late

CIS 054 COURSE OUTLINE (subject to change)

Week
Date

Lecture Topic
Chapter numbers refer to
C++ How to Program 7/e
Lab Assignment
Page numbers refer to
C++ How to Program 7/e
Homework
Page numbers refer to
C++ How to Program 7/e
Points this week
Week 1
Feb 1
Due
Feb 8

Class Orientation
Chapter 1 Intro to Computers

Operating Systems, C/C++

Program Design

Paycheck Program Copy the code into a Word document and submit using Moodle. (10 points)

Paycheck project code

Read Chapter 1 and do the Self-Review Exercises. Do not turn in the Self-Review Exercises for any of the chapters.

Answer questions from Exercises 1.4 through 1-11 pages 36-37. Submit using Moodle. (10 points)

20
Week 2
Feb 8
Due
Feb 15

Chapter 2 Visual C++ IDE
Help, Variables

Program Design

Largest-Smallest Exercise 2.23 page 66
Odd-or-Even Exercise 2.24 page 66.
Copy the code for each program in to a Word document and submit using Moodle. (10 points each)

Read Chapter 2 and do the Self-Review Exercises.

Answer questions from Exercises 2.7 through 2.15 pages 64-65. Submit using Moodle. (10 points)

30
Week 3
Feb 15
Due
Feb 22
Chapter 4 Control Statements: Part 1
Control Structures, if.else, while, loops, ++/--
Gas Mileage Program Exercise 4.13 page 156. Copy the class code, the test application, and a screen-shot showing your program has correctly processed three sets of data into a Word document and submit using Moodle. (20 points)

Read Chapter 4 and do the Self-Review Exercises.

Answer questions from Exercises 4.11 and 4.12 pages 155-156. Do not use the computer to find answers to these problems. Submit using Moodle. (10 points)

30
Week 4
Feb 22
Due
Mar 1
Chapter 5 Control Statement: Part 2
for do..while, switch, break, continue, Logical Operators
Total Sales Program Exercise 5.14 page 204. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 5 and do the Self-Review Exercises.

Answer questions from Exercise 5.4 page 202. Submit using Moodle. (10 points)

30
Week 5
Mar 1
Due
Mar 8
Chapter 6 Functions and Recursion
Scope, Math Library, Passing parameters, Function Prototypes, Random numbers, Call stack
Parking Program Exercise 6.12 page 273. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 6 and do the Self-Review Exercises.

Answer questions from Exercise 6.11 page 272. Submit using Moodle. (10 points)

30
Week 6
Mar 8
Due
Mar 15
Chapter 7 Arrays and Vectors
for-statement, passing arrays, multidimensional arrays, command-line args
Airline Reservation Program Exercise 7.20 page 337. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 7 and do the Self-Review Exercises.

Answer Exercises 7.6 through 7.9 pages 334-335. Submit using Moodle. (10 points)

30
Week 7
Mar 15
Due
Mar 22

Chapter-8 Pointers
pointer expressions, pointer arithmetic, relation between pointers and arrays, arrays of pointers, pointer-based string processing, function pointers.
 
6:00-7:50
8:00-9:50
Java Lecture Lab
C++ Lab (attendance
is optional)
Lecture

Tortoise and Hare Exercise 8.12 pages 384-385. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (30 points)

Read Chapter 8 and do the Self-Review Exercises.

Answer questions from Exercises 8.7 through 8.11 pages 383-384. Submit using Moodle. (10 points)

40
Week 8
Mar 22
Due
Mar 29
Chapter 3 Intro to Classes and Objects
Objects, Methods and Parameters
Invoice Program Exercise 3.13 page 107. Copy the class code, the test application and a screen-shot showing the results of your program execution into a Word document and submit using Moodle. (10 points)

Read Chapter 3 and do the Self-Review Exercises.

Answer questions from Exercises 3.5 through 3.10 page 107. Submit using Moodle. (10 points)

20
Week 9
Mar 29
Due
Apr 5

Chapter 9 Classes and Objects
reference

Chapter 10 Classes Part 2
this

Rational Number Program Exercise 9.6 page 427. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapters 9 and 10. Do the Self-Review Exercises.

Answer the question from Exercises 9.3 page 426. Submit using Moodle. (5 points)

25
Week 10
Apr 5
Due
Apr 12
Chapter 12 Inheritance
base and derived classes, constructors w/ inheritance
Savings Account Program Exercise 10.7 page 463. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 12 and do the Self-Review Exercises.

Answer questions from Exercises 10.3 though 10.5 pages 462-463. Submit using Moodle. (10 points)

30
Week 11
Apr 12
Due
Apr 26
Chapter 11 Operator Overloading
 
6:00-7:50
8:00-9:50
C++ Lecture Lab
Java Lab (attendance
is optional)
Lecture
Complex Number Program Exercise 11.8 pages 514-516. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 11 and do the Self-Review Exercises.

Answer question from Exercises 11.6 page 514. Submit using Moodle. (5 points)

25
Week 12
Apr 19

SPRING BREAK
Apr 18 - Apr 24

SPRING BREAK
Apr 18 - Apr 24
SPRING BREAK
Apr 18 - Apr 24
 
Week 13
Apr 26
Due
May 3

Chapter 13 Polymorphism
abstract classes

Package Shipping Program Exercise 12.9 page 570. Copy the code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 13 and do the Self-Review Exercises.

Answer questions from Exercises 13.3 through 13.8 page 624. Submit using Moodle. (10 points)

30
Week 14
May 3
Due
May 10
Chapter 16 Exception Handling
Chapter 14 Templates
 
6:00-6:50
7:00-9:50
C++ Lecture Lab (attendance
is optional)
Java Lab (attendance
is optional)
Lecture & Lab
Polymorphic Package Shipping Program Exercise 13.15 page 624. Copy the code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapters 16 and 14. Do the Self-Review Exercises.

Answer questions from Exercises 16.18 through 16.22 page 711. Submit using Moodle. (10 points)

10
Week 15
May 10
Due
May 17
Chapter 15 Stream I/O
 
6:00-7:50
8:00-9:50
Java Lecture Lab
C++ Lab (attendance
is optional)
Lecture
Point Class Exercise 15.15 page 682. Copy the class code, the test application, and a screen-shot showing your program execution into a Word document and submit using Moodle. (20 points)

Read Chapter 15 and do the Self-Review Exercises.

Answer questions from Exercise 15.6 page 681. Submit using Moodle. (10 points)

30
Week 16
May 17
Due
May 24
Chapter 17 File Processing
sequential access files, random access files
File Matching Program Exercise 17.7 page 750-751. Copy the code and a screen-shot showing your program execution into a Word document and submit using Moodle. Do not copy the output file into the Word document. (40 points)

Read Chapter 17 and do the Self-Review Exercises.

Answer questions from Exercise 17.5 and 17.6 page 750. Submit using Moodle. (10 points)

50
Week 17
May 24
Homework
Due
May 27

Chapter 18 Strings

FINAL EXAM

FINAL EXAM
(80 points)

Read Chapter 18 and do the Self-Review Exercises.

Answer questions from Exercises 18.4 through 18.6 page 779. Submit using Moodle. (10 points)

90
  TOTAL POINTS 390 150 540

Important Dates Spring 2011
Regular semester courses
(all information subject to change)
1/31
Spring Semester Begins
2/11
Last day to withdraw for a refund
2/13
Last day to use ADD CODES
2/14
SJCC instructor census reports due
2/18-2/21
Presidents' Day (campus closed)
2/25

Last day to withdraw without a "W" on record
Last day to apply for a refund (if dropped by 2/11)

Last day to submit P/NP forms to A&R

3/4
Graduation/Certificate petitions due
4/18-4/24
Spring Break - campus closed
4/28
Last day to withdraw with a "W"
5/20
English Finals (no regular day classes)
5/23-5/26
5/23-5/24
SJCC Final Exams (Monday-Thursday)
McElroy CIS-41 Exams Monday 5/23 @ 6:00pm
   or Tuesday 5/24 @ 10:45am or 6:00pm
5/27
SJCC Commencement
6/8
Grades by phone 223-0300 or https://myweb.sjeccd.edu
    
Office Hours and Schedule Spring 2011
Dan McElroy@sjcc.edu
Office: T410 Technology Building
 
MON
TUE
WED
8:00
 
 
 
9:00
 
 
 
10:00
 
CIS-41
T213
(10:45-1:05)
 
11:00
 
 
12:00
 
1:00
 
Office-T410
 
2:00
 
Academic
Senate
 
 
3:00
Office-T410  
Dept Meeting
3rd Wed
each Month
4:00
 
5:00
Office-T410 
6:00
CIS-73
T210
T205
CIS-54
CIS-84
T209
 
7:00
 
8:00
 
9:00
 
10:00