CS 161
Introduction to Programming
and Problem Solving
Chapter 2
Introduction
Herbert G. Mayer, PSU
Status 9/18/2014
1
Syllabus
This is CS 161
Acknowledgments
Prerequisites
Course Material
Working Standards
References
2
This is CS 161
Fall 2014, CS 161, Introduction to Programming and
Problem Solving
Derived from PSU material, customized for CCUT
Students get introduced to typical engineering
problems that can often be solved via programming
Focus in CS 161 is the C language
Usually relying on compilers that are free of license
fees
3
Acknowledgments
Material inherited from my own, old lectures notes
on CS 161
Also material inherited from PSU prof. Karla Fant,
CS 161
4
Prerequisites
Some understanding of using computers
ECE 102 Engineering Computation - recommended
High School mathematic skills, specifically Algebra
and trigonometry
Access to a C or C++ programing development
environment
5
Course Material
Instructor Notes
“The C Programming Language”, 2nd Edition, Brian
Kernighan, Dennis Richie, Prentice Hall © 1988 or
newer, required
6
Working Standards
Your key contributions in this class will be working
source programs
Part of that work is documentation, usually in the
form of comments
Make sure you do comment, not what is evidently
visible from the source, but share your thoughts you
went through when you wrote your source.
For example, when you write code:
Index ++; // increment the index; no need to comment
All readers can see that you increment the index.
Don’t bother saying that you increment it. We all
know. Detail, what the index is used for, what the
next element so identified means, what is behind it?
7
Working Standards
Include in your comments your name, the date last
modified, a description of the project
Include the class, school, name of the project
Also, if you rely on other sources (books, internet,
advisors) do share which source you are using
When updating or upgrading your program, ensure
that the new source and the comments you leave
correspond
8
Text Books Recommended
1. The C Programming Language, 2nd edition,
Kernighan and Ritchie, Prentice Hall, ISBN 0-13110362-8, © 1988 or newer
9