Introduction to Programming Concepts

advertisement
SYLLABUS
Introduction to Programming Concepts
CCSA 126
Introduction to Programming Concepts
Course Syllabus
GENERAL COURSE INFORMATION
Course Number:
Credit Hours:
Prerequisites:
Course Description:
CCSA 126
3
None
This course is a hands-on introduction to analyzing, designing, coding, and testing
computer programs. Students will develop algorithms for problem solving with an
emphasis on good programming practices. Students will use programming techniques
including control structures, arrays, and subprograms to design and code basic
programs using a modern computer language. Other topics include working with data,
number systems, and an introduction to object-oriented and event-driven programming.
This course prepares students for software development courses in programming and
web development.
FACULTY INFORMATION
Name/Title:
Office Phone:
Email address:
TEXTBOOK(S)
Text Title
Programming in C (4th Edition)
9780672331411
Text Author
Stephen Kochan
Text Publisher
Addison-Wesley
Professional
REFERENCES/BIBLIOGRAPHIES
Author(s)
Ophir Frieder,
Gideon Frieder,
David Grossman
Zigurd Mednieks,
Laird Dornin, G.
Blake Meike,
Masumi Nakamura
Title
Computer Science
Programming Basics in Ruby
Publisher, Copyright Date
O'Reilly Media (May 1, 2013)
ISBN Number
ISBN-10: 1449355978
ISBN-13: 978-1449355975
Programming Android: Java
Programming for the New
Generation of Mobile Devices
O'Reilly Media; Second
Edition (October 19, 2012)
ISBN-10: 1449316646
ISBN-13: 978-1449316648
Springer; 2013 edition (March
13, 2013)
ISBN-10: 3642376509
ISBN-13: 978-3642376504
Programming PHP
O'Reilly Media; Third Edition
(February 22, 2013)
ISBN-10: 1449392776
ISBN-13: 978-1449392772
Dr. Dobb’s Journal
Drdobbs.com
Information Week
Copyright © 2013 UBM Tech
Programming Logics: Essays
Andrei Voronkov
in Memory of Harald
(Editor), Christoph
Weidenbach (Editor) Ganzinger
Kevin Tatroe, Peter
MacIntyre, Rasmus
Lerdorf
SOFTWARE
Microsoft Visual Studio 2012
OTHER MATERIALS/RESOURCES
A flash drive or other storage device to store assignments.
PNU-CC, Introduction to Programming Concepts – CCSA 126
Page |2
ASSESSMENT METHODS AND EVALUATION
Assessment:
10 Programming Assignments
Midterm Exam
Final Exam
Total
Weight
30%
25%
45%
100%
GRADING SCALE (Grading Scale is at the discretion of the faculty)
A=
B=
C=
D=
F=
90%
80%
70%
60%
Below
TOTAL
- 100%
- 89%
- 79%
- 69%
60%
100%
PURPOSE OF ASSESSMENTS
1.
2.
3.
10 Programming Assignments: Completion of the homework assignments will allow the student to apply the
theory and concepts learned from reading the textbook chapters.
To evaluate the student progress and understanding.
Final Exam: Summative evaluation of skills and understanding of theory and concepts.
DESCRIPTION OF ASSIGNMENTS
1.
Assignment 1 (3%: 2 parts x 1.5%)

Create a program in Visual Studio that prints your name in the output window and waits for the user to
press a key before exiting. Take a screen shot of your development environment.

Solve this puzzle.
Each Sudoku has a unique solution that can be reached logically without guessing. Enter digits from 1 to 9 into
the blank spaces. Every row must contain one of each digit. So must every column, as must every 3x3 square.
Complete this Sudoku puzzle and save the result.
2.
Assignment 2 (3%: 1 part x 3%)
Write a program that asks the user to enter an integer, a floating point number, and a character. Be sure to
explain to the user what each data type looks like so they know what to enter. After all three values have
been entered, ask the user to press a key to terminate the program. Turn in screen shots of your program
running.
PNU-CC, Introduction to Programming Concepts – CCSA 126
Page |3
3.
Assignment 3 (3%: 1 part x 3%)
Write a program that asks the user to enter in four tests grades on a scale of 0 to 100 points. Output the
average of the four test grades. Turn in screen shots of your program running with at least 3 different sets of
test data.
4.
Assignment 4 (3%: 1 part x 3%)
Write a program to print out an isosceles right triangle made from asterisks based on the length of the base
entered by the user. For example, if the user enters 5, the triangle should look like this:
*
* *
* * *
* * * *
* * * * *
Require the user to hit a key before the program terminates.
5.
Assignment 5 (3%: 2 parts x 1.5%)

Write a program that asks the computes the gas mileage for the user’s vehicle. Have the user enter
the number of gas tanks to use for computation. Then, based on the user’s entry, ask the user to
enter the miles driven and amount of gas for each tank of gas. Once this is done, compute the gas
mileage for that vehicle based on the data entered.

Write a program to compute the Factorial of the integer entered by the user. The Factorial function
(!) is defined as follows: n! = n * n-1 * … * 3 * 2 * 1. For example, 4! = 4 * 3 * 2 * 1 = 24.
6.
Assignment 6 (3%: 1 part x 3%)

Ask the user to enter numbers. When he or she enters 0, the program will inform the user of the
largest number they entered and the smallest.
Example run:
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
Please enter a number ( 0 to exit):
12
-34
78
13
-3
94
63
0
The largest number you entered was 94
The smallest number you entered was -34
7.
Assignment 7 (3%: 1 part x 3%)
Shipping Calculator: Speedy Shipping company will ship your package based on how much it
weighs and how far you are sending the package. They will only ship small packages up to 10
pounds. You need to have a program that will help you determine how much they will charge. The
charges are based on each 500 miles shipped. They are not pro-rated, i.e., 600 miles is the same
charge as 900 miles.
Here is the table they gave you:
Package Weight
2 pounds or less
More than 2 but not more than 6
More than 6 but not more than 10
PNU-CC, Introduction to Programming Concepts – CCSA 126
Rate per 500 miles shipped
$1.50
$3.70
$5.25
Page |4
Here is one test case.
Test Case Data:
Weight:
Miles:
5.6 pounds
1200 miles
Expected results:
Your shipping charge is $11.10
8.
Assignment 8 (3%: 1 part x 3%)
Repeat the assignment from assignment 6, but this time use an array to store the numbers entered by the
user (ask them how many they will enter first) and use a loop to go through the numbers to find the largest
and smallest after all numbers have been entered.
9.
Assignment 9 (3%: 1 part x 3%)
Modify your program from Assignment 8 to use a function to compute the largest entered number and
another function to compute the smallest number entered.
10. Assignment 10 (3%: 1 part x 3%) – “Take Your Order” project
Background: Dr. Macon is opening up a restaurant. She has hired some PNU students (part
time) to take orders. There is a requirement to take orders quickly, and to read a summary of the
order (including the total price) back to the customer after they have finished picking what they
want. A computer program is required to help with this task.
Specification:

The user of this program is an employee taking an order from a customer.

Each time the program runs it takes a single customer’s order.

Print a welcome message that the user can read to the customer.

Print a menu of the items that can be ordered. By selecting something from the menu, the
user is adding that item to the customer’s order.

Each time a new item is added to the customer’s order, the current total price is printed.

The menu is printed each time the user is ready to add a new item.

When the customer doesn’t want to order any more items, the user enters an item that
indicates the customer is done.

A summary of the order is presented to the user, including the total price for this order.
The price must be presented in dollars and cents.

Print a “nice” message for the user to read to the customer when they are done ordering
that includes the items ordered, and the total price. The program exits.
Requirements:

Create a program that meets the above specifications.
This program must:
use a do – while loop.
Do not use a “break” to exit the do – while loop. You must use break inside the
switch, but don’t use it to break the loop.
use a switch control structure
use features of the formatted output function printf, including right justification,
and width specifiers for printing the menu prices, and all output from the
program must be neatly formatted and readable. Columns must line up correctly.

You must have at least 5 different items - of your own creation – do not use the sample
- on your menu each with a different price.
PNU-CC, Introduction to Programming Concepts – CCSA 126
Page |5

Be creative, create your own restaurant, invent your own items, etc. – be aware that your
grade will be based on the correct functionality of the program – meeting the above specs
and requirements, and the correct use of the constructs from the C language.

On the next page is a sample of what the program output might look like. The bold
characters, i.e., item numbers, are the only thing entered by the user, your program
generates everything else.
MAJOR TOPICS/ CONCEPTS/ SKILLS/ ISSUES
Week
No.
1
2
3
4
5
6
7
8
Topic Covered
Setting up/using Visual Studios
Basic syntax, writing a program
Compiling, running, and debugging
Variables, data types, and expressions
Assignments, sequence statements
Input and Ouptut
Looping
Logical expressions
Reading
Chapter 1
Chapter 2
Chapter 3
Chapter 4
Chapter 4
Chapter 4
Chapter 5
Chapter 6
9
10 - 11
12 - 13
14 - 15
16-17
Making Decisions
Working with Arrays
Working with Funcitons
Putting it all together
Final Exam
Chapter 6
Chapter 7
Chapter 8
Assignments
Due
Assignment 1
Assignment 2
Assignment 3
Assignment 4
Assignment 5
Assignment 6
Mid Term Exam
Assignment 7
Assignment 8
Assignment 9
Assignment 10
Contact
Hours
3
3
3
3
3
3
3
3
3
6
6
6
MAJOR LEARNING OUTCOMES WITH EVIDENCE, CORE COMPETENCIES AND INDICATORS
Students will be able to explain number systems and the internal representation of data.
Corresponding Evidence of Learning
 Student will be able to know how computers represent data internally
 Student will be able to define basic storage units such as byte, Kbyte, Mbyte.
 Student will be able to convert numbers from binary to decimal and from decimal to binary
Core Competency: Think
Indicators
 Employ the facts, formulas, procedures of the
discipline
Assessments
 Locally developed exam/objective
 Problem-solving quiz
Students will be able to solve problems with simple sequence, selection, and repetition
statements by using different data type variables, expressions, and flow of control.
Corresponding Evidence of Learning
 Student will be able to define variables and constants, select the correct data type for a variable, and describe
the relationship between variables and memory.
 Student will be able to build expressions involving the assignment and the basic mathematical operators (+, -,
*, /, %).
 Student will be able to evaluate logical expressions involving relational and logical operators
 Student will be able to know when to use a selection and/or a repetition statement
 Student will be able to solve problems using IF, nested IF statements and the Case structure
 Student will be able to solve problems using counter-controlled, sentinel and nested loops.
Core Competency: Think
Indicators
 Analyze data, ideas, patterns, principles,
perspectives
 Draw well-supported conclusions
Assessments
 Classroom assessment technique
 Locally developed exam/objective
 Problem-solving quiz
PNU-CC, Introduction to Programming Concepts – CCSA 126
Page |6
Core Competency: Act
Indicators
 Employ facts, formulas, procedures of the discipline
Assessments




Classroom assessment technique
Locally developed exam/objective
Problem-solving quiz
Project
Students will be able to create and use arrays of data.
Corresponding Evidence of Learning
 Student will be able to list the benefits of using arrays
 Student will be able to describe how arrays are represented in memory
 Student will be able to solve problems using arrays
Core Competency: Think
Indicators
 Analyze data, ideas, patterns, principles,
perspectives
 Draw well-supported conclusions
Assessments
 Classroom assessment technique
 Problem-solving quiz
Core Competency: Act
Indicators
 Employ facts, formulas, procedures of the discipline
Assessments




Classroom assessment technique
Locally developed exam/objective
Problem-solving quiz
Project
Students will be able to create and call modules.
Corresponding Evidence of Learning
 Student will be able to list the benefits of decomposing large problems into modules
 Student will be able to know how to create a module and call the module
 Student will be able to solve problems using modules
Core Competency: Think
Indicators
 Analyze data, ideas, patterns, principles,
perspectives
 Draw well-supported conclusions
Assessments
 Classroom assessment technique
 Problem-solving quiz
Core Competency: Act
Indicators
 Employ facts, formulas, procedures of the discipline
Assessments




Classroom assessment technique
Locally developed exam/objective
Problem-solving quiz
Project
Special Note: This syllabus was developed by Valencia College, Orlando, Florida, United States of America.
PNU-CC, Introduction to Programming Concepts – CCSA 126
Page |7
Download