home

=Period 8 Computer Programming II in C++=

**Thursday - Wednesday 6/3-9/10 Objective: Final Exam Program.**

** Final Exam Program: ** __Program:__ **Shop.cpp**

**Tuesday 6/1/10 Objective: Explore the standard template library and vectors.**

**Do Now:** __Read:__ Read pages 112- 116 in the paper back Dawson textbook.

__Program:__ **HighScores.cpp**
 * Assignment: **

Objective: Explore the standard template library and vectors. **
 * Friday 5/28/10

**Do Now:** __Read:__ Read pages 105 - 112 in the paper back Dawson textbook.

__Program:__ **HerosInventory3.cpp**
 * Assignment: **

media type="custom" key="6249845"
 * Thursday 5/27/10

Tuesday & Wednesday 5/25,26/10 Objective: Explore the standard template library and vectors. **

**Do Now:** __Read:__ Read pages 99 - 105 in the paper back Dawson textbook.

__Program:__ **HerosInventory2.cpp**
 * Assignment: **

**Thursday - Monday 5/20-24/10 Objective: Explore the concept of structures.**

**Do Now:** __Read:__ Read pages 195 - 200 in the green and gold textbook.

__Program:__ **Struct.cpp** Do Exercise 10-7 which starts on page 197. For number 1, type in the code from the blue sections in the textbook on page 196 to 197.
 * Assignment: **

__Program:__ **Donors.cpp** Do Exercise 10-8 which starts on page 199.

Objective: Use math library functions.**
 * Wednesday 5/19/10

** Assignment: ** __Program in Notebook:__ **PowerCircTrigLog.cpp**

Objective: Write code for function definitions.**
 * Monday 5/17/10

**Do Now:** __Read:__ Read the function prototypes and main function for the program ReduceFractions.cpp in your white notebook. Read the test data and output pages 4 to 10 of the document. Determine what must be included in the function definitions. Discuss you thoughts with another student. Share your thoughts with the class.

__Program:__ **ReduceFractions.cpp** Enter the code from the direction sheets in your notebook. Add the missing code for the function definitions from page 3, based on the output provided. Test the program thoroughly. Have another student test your program and you test another student's program.
 * Assignment: **

__Paper and Pencil:__ Are the comments helpful in explaining main function code? Why or why not? What could be done to make this program better?
 * Ticket out Door: **

Objective: Use library functions.**
 * Friday-Friday 5/7-14/10

**Do Now: ** __Read:__ P. 170 - 174 Chapter 9 Section 3 and Summary of the green and gold textbook Popular Math Functions Trigonometric and Logarithmic Functions Functions for Working with Characters Key Terms Summary
 * Using Library Functions

Assignment: ** __Programs:__
 * P. 171 Power.cpp** (Just use the function call. Do not type the prototype or function code because it is built in.)
 * P. 171 Circ.cpp** (Just use the function call. Do not type the prototype or function code because it is built in.)
 * P. 172 TrigLog.cpp** (Just use the function call. Do not type the prototype or function code because it is built in.)
 * P. 173 CharFun.cpp** (Just use the function call. Do not type the prototype or function code because it is built in.)

__Paper and Pencil:__ P. 173 Section 9.3 Questions 1-6
 * Ticket out Door: **

Objective: Use functions to break programs into parts.**
 * Tuesday - Thursday 5/4-6/10

**Do Now: ** __Read:__ P. 167 - 169 Chapter 9 Section 2 of the green and gold textbook Dividing the Series Program into Functions
 * Getting Data to and from Functions

Assignment: ** __Programs:__
 * PassRef.cpp**
 * CtoF.cpp** (In your notebook)

__Paper and Pencil:__ P. 170 Section 9.2 Questions 1-7
 * Ticket out Door: **

Objective: Use functions to break programs into parts.**
 * Thursday 4/29/10 & Monday 5/3/10

**Do Now: ** __Read:__ P. 163 - 167 Chapter 9 Section 2 of the green and gold textbook Scope of Variables Getting Data to and from Functions
 * Data and Functions

Assignment: ** __Programs:__
 * Scope.cpp**
 * PassVal.cpp**

__Paper and Pencil:__ 1. Explain the difference between **passing by value** and **passing by reference (address)**. 2. What is the difference between **arguments** and **parameters**?
 * Ticket out Door: **

Objective: Use functions to break programs into parts.** __Paper and Pencil:__ Green and gold textbook P. 162 Section 9.1 Questions 1 - 3, 5, 6. __Programs:__ Problem 9.1.1 P. 162 GasCheck.cpp Problem 9.1.2 P. 162 ValTest.cpp
 * Monday - Wednesday 4/26-28/10
 * Assignment: **

Objective: Use functions to break programs into parts.**
 * Friday 4/23/10

**Do Now: ** __Read:__ P. 156 - 158 Chapter 9 Section 1 of the green and gold textbook
 * How to Build Programs with Functions**

__Program:__ **Proto1.cpp** Code and output in your notebook.
 * Assignment: **

**Ticket out Door: ** __Paper and Pencil:__ 1. Explain the difference between **top-down design** and **bottom-up design**. 2. Which of these concepts is **easiest** for you to understand and **why**. 3. Which of those 4 concepts is the **hardest** for you to understand and **why**.
 * Organization, Autonomy, Encapsulation, Reusability** (see page 158)

**Friday - Thursday 4/16-22/10 Objectives: Produce a portfolio of your Chapter 3 (and Chapter 8 of green gold book) assignments.** Use for loops to iterate over sequences. Use objects, which combine data and functions. Use string objects and their member functions to work with sequences of characters. Use arrays to store, access, and manipulate sequences of any type. Use multidimensional arrays to better represent certain groups of information.

**Do Now: ** Read P. 94 -95 Chapter 3 Summary Read P. 95-96 Chapter 3 Questions and Answers

Create a Chapter 3 portfolio with the filename, **Ch3PortfolioCPP.doc** for P. 71-97 **Ch 3** **For Loops, Strings, and Arrays: Word Jumble**
 * Assignment: **

P. 72 Counter.cpp P. 78 StringTester.cpp P. 83 HerosInventory.cpp P. 89 TicTacToeBoard.cpp P. 91 WordJumble.cpp ForLoop.cpp Backward.cpp OddLoop.cpp SumItUp.cpp AB123.cpp OuterInnerLoop.cpp Possible.cpp FiveFour.cpp Vowels.cpp AlphabetPositions.cpp StringInput.cpp CharacterCountB.cpp InLine.cpp WasteChalk.cpp StringToNumber.cpp EnumTest.cpp
 * Programs: (You have already done these.) **

Create a document in Microsoft Word with the filename, **Ch3PortfolioCPP.doc**, by starting with the template below. Save to the desktop and upload to your Gaggle digital locker. When it is complete, get permission from Miss Hangen to print it. In it include the follow sections:
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Word Document: **
 * **P. 97 Discussion Questions 1-5: Answer the questions in sentence form.**
 * **P. 97 1-3 Exercises**
 * **Paste screen shots of these programs into your Word document.**
 * InLine.cpp
 * WasteChalk.cpp
 * StringToNumber.cpp
 * EnumTest.cpp
 * SumItUp.cpp
 * **Paste screen shots of your output for these programs into your Word document.**
 * **Get permission from Miss Hangen to print it.**

Objective: Practice with enum.**
 * Wednesday & Thursday 4/14,15/10

<span style="font-family: 'Comic Sans MS',cursive;">**Do Now:** Read in the green and gold textbook, pages 193-195 Ch 10 Section 3 Using Enum.

EnumTest.cpp P. 193 in green and gold textbook
 * Program: **

P. 195 Section 10.3 Questions 1-6 Problem 10.3.1
 * Paper and Pencil: **

Objective: Experiment with bad data checking for characters provided when numbers are asked for.**
 * Monday 4/12/10

**<span style="font-family: 'Comic Sans MS',cursive;">Do Now: ** Study the print out of the source code of **WasteChalk.cpp** in your notebook.


 * Program: **
 * StringToNumber.cpp**

__Objective:__ Decide on the best structure to do a specific task in a program.
 * Thursday & Friday 4/8,8/10**

Study the print out of the source code of **WasteChalk.cpp** in your notebook.
 * <span style="font-family: 'Comic Sans MS',cursive;">Do Now: **

** Program: ** Finish **WasteChalk.cpp

<span style="font-family: 'Comic Sans MS',cursive;">Discussion :** Catching bad data and default with the switch case structure Catching when a letter was entered into a numeric variable @http://www.codeguru.com/forum/showthread.php?t=231054

**Tuesday & Wednesday 4/6,7/10** __Objective:__ Decide on the best structure to do a specific task in a program.

Study the print out of the execution of WasteChalk.cpp in your notebook.
 * <span style="font-family: 'Comic Sans MS',cursive;">Do Now: **

** Program: ** WasteChalk.cpp

**Thursday 4/1/10 Objective:** Lorem ipsum dolor sit amet, consectetur adipiscing elit.

<span style="font-family: Arial,Helvetica,sans-serif;">**Paper and Pencil:** Fusce pellentesque semper purus vehicula dapibus.

Quisque.cpp Example here.
 * Program:**

**__Objective:__ Decide on the best structure to do a specific task in a program.**
 * Thursday 4/1/10**

**Do Now:** Look at the picture and decide what structures would work well to produce a program that would provide a menu with choices of what to write on the board a specified number of times, using C++ instead of VB.

Program: **WasteChalk.cpp** Write the program. []
 * __Assignment:__**


 * <span style="background-color: #800000; color: #ffff00; font-family: Arial,Helvetica,sans-serif;">__Ticket out the Door:__ **
 * Have a nice vacation and a Happy Easter.**

**Wednesday 3/31/10 Objective:** Write programs that demonstrate the use of character arrays.

<span style="font-family: Arial,Helvetica,sans-serif;">**Paper and Pencil:** cin.get & cin.ignore

InLine.cpp
 * Program:**

Objective:** Write programs that demonstrate the use of getline, for loop, cin.ignore, size, counting, and a string as a character array.
 * Tuesday 3/30/10

** Program: ** CharacterCountB.cpp

Objective:** Write programs that demonstrate the use of getline for string object input.
 * Monday 3/29/10

**Programs:** StringInputBlank.cpp Continue your work with this program. AlphabetPositions.cpp Refer to the directions and output provided in your notebook.

Objective:** Write programs that demonstrate use of string objects and the functions find, erase, and size, in addition to using the fact that strings are character arrays.
 * Wednesday - Friday 3/24 - 26/10

<span style="font-family: Arial,Helvetica,sans-serif;">** Do Now: ** What are the data types of these variables in the code below? 1. **Location** 2. **C** 3. **Alphabet** 4. **Letter**
 * Paper and Pencil:**

Location = Alphabet.find("u"); Alphabet.erase(Location, 1); C = Alphabet.size; Letter = Alphabet[Position];

**Discussion:** <span style="font-family: Arial,Helvetica,sans-serif;">Look at the Vowel.cpp programs each other did.

Continue your work with these programs. Vowels.cpp AlphabetPositions.cpp Refer to the directions and output provided in your notebook.
 * Programs:**

What will help you with the program you are working on?
 * Ticket out Door: **

Objective:** Write programs that demonstrate use of string objects and the functions find, erase, and size, in addition to using the fact that strings are character arrays.
 * Tuesday 3/23/10

<span style="font-family: Arial,Helvetica,sans-serif;">** Do Now: ** Re-read pages 77-82.

**Programs:** Vowels.cpp AlphabetPositions.cpp Refer to the directions and output provided in your notebook.

What is an idea you have for a program that demonstrates that you understand strings?
 * Ticket out Door: **

Objective:** Write programs that demonstrate use of string objects and the functions find, erase, and size, in addition to using the fact that strings are character arrays.
 * Monday 3/22/10

<span style="font-family: Arial,Helvetica,sans-serif;">** Do Now: ** Re-read pages 77-82.

Miss Hangen will give an explanation and examples of working with string objects.
 * <span style="font-family: 'Comic Sans MS',cursive;">Explanation: **

**Programs:** Vowels.cpp AlphabetPositions.cpp Refer to the directions and output provided in your notebook.

What is an idea you have for a program that demonstrates that you understand strings?
 * Ticket out Door: **

Objective**: To review for loops and strings. <span style="color: #000000; font-family: 'Comic Sans MS',cursive;"> media type="custom" key="5670639" Vowels.cpp** Write source code for this output.
 * Friday 3/19/10
 * Do Now:**
 * Program:

This program will display the lowercase letters of the alphabet without the vowels. It will also count how many letters are not vowels. There is no input required by the user.
 * <span style="font-family: 'Courier New',Courier,monospace;">Vowels.cpp by Your Name

Here are the letters of the alphabet that are not vowels. bcdfghjklmnpqrstvwxyz

There are 21 letters that are not vowels.

The Vowel.cpp program has ended. **

What is an idea you have for a program that demonstrates that you understand strings?
 * Ticket out Door: **

**Tuesday & Wednesday 3/16,17/10 Objective**: To use the fundamental counting principal of probability, nested for loops, and ASCII codes to create a program using letters of the alphabet. <span style="color: #000000; font-family: 'Comic Sans MS',cursive;"> FiveFour.cpp Write a program that will display a numbered list of all the possible ways to answer a 4-question multiple choice test with 5 choices for each answer.
 * Program:**
 * Directions for FiveFour.cpp:**

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**Do Now:** <span style="font-family: Arial,Helvetica,sans-serif;">**Think - Pair - Share** Can you use numbers to refer to letters of the alphabet? What are ASCII Codes? Where can you find them? How do you use them in C++?
 * Monday 3/15/10**
 * Objective**: To use the fundamental counting principal of probability, nested for loops, and ASCII codes to create a program using letters of the alphabet.

Possible.cpp Write a program that uses nested loops to display a numbered list of all the possible ways to answer a 3-question multiple choice test with 4 choices for each answer You will need a cout.setf function and setw to make the output appear in columns. The beginning of the code is provided in your notebook.
 * Program:**
 * Directions for Possible.cpp:**


 * [[image:PossibleOutput.PNG width="479" height="300"]]

Friday 3/12/10 <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: ** OutterInnerLoop.cpp (Directions in notebook)

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Programs to Look at Together: ** OddLoop.cpp SumItUp.cpp
 * Thursday 3/11/10

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Programs to Look at Together: ** NameLoop.cpp
 * Wednesday 3/10/10

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Programs to Look at Together: ** AB123.cpp NameLoop.cpp
 * Tuesday 3/9/10

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**Reading:** **Ch 8 Loops: Summary and Questions** (This is chapter 8 in the green and gold textbook.) **Ch 8 Loops: Summary and Questions** (This is chapter 8 in the green and gold textbook.) NameLoop.cpp OddLoop.cpp SumItUp.cpp AB123.cpp
 * Monday-Wednesday 3/8-10/10**
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Paper and Pencil: **
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Programs: **

** Friday 3/5/10 ** <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**Program:** Backward.cpp **Check your 3rd marking period assignments!!!**

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: ** <span style="color: #000000; font-family: Arial,Helvetica,sans-serif;">**Ch 8 Loops: Summary and Questions** (This is chapter 8 in the green and gold textbook.) <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**Paper and Pencil:** Continue working on **Ch 8 Loops: Summary and Questions** (This is chapter 8 in the green and gold textbook.) ForLoop.cpp
 * Thursday 3/4/10 **
 * Program:**

** Wednesday 3/3/10 <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: ** **Ch 8 Loops: Summary and Questions** (This is chapter 8 in the green and gold textbook.) Start working on **Ch 8 Loops: Summary and Questions** (This is chapter 8 in the green and gold textbook.)
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Paper and Pencil: **

**Introducing Word Jumble** on pages 90 - 94 in Dawson paper textbook. WordJumble.cpp
 * Monday, Tuesday 3/1,2/10**
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: **
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: **


 * Friday 2/26/10**
 * Snow and Wind Day -- No School **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: ** Understanding C-Style Strings on pages 87 - 88 in Dawson paper textbook. P. 89 TicTacToeBoard.cpp
 * Thursday 2/25/10
 * Using Multidimensional Arrays** on pages 88 - 90.
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: Using Arrays** on pages 83 - 87 in Dawson paper textbook. P. 83-84 HerosInventory.cpp
 * Wednesday 2/24/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: Understanding Objects** on pages 75 - 82 in Dawson paper textbook. P. 78 StringTester.cpp
 * Tuesday 2/23/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Reading: ** Read pages 71 - 75 in Dawson paper textbook. P. 72- 73 Counter.cpp
 * Monday 2/22/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Program: Work on this together.** GuessMyNumber2.cpp P. 69 Exercise 3
 * Wednesday - Friday 2/17-19/10

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Do Now: ** Finish Discussion Questions and Wiki. P. 69 Do Exercises 1-3
 * Tuesday 2/16/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Assignment: **

Random Read of Questions and Answers on page 67 and 68. Look at RandomStudent.cpp Discussion Questions and Wiki.
 * Tuesday 2/9/10**

Go over Summary.
 * Monday 2/8/10**

Read the Summary and Questions and Answers on pages 66 to 68 in the Dawson paper back textbook. Think - Pair - Share: Think about the discussion questions on page 68 and jot some answers on paper. Talk it over with a couple of students in the class to expand your thinking and answers. Edit http://hangencpp.wikispaces.com/ with your groups answers. P. 69 Do the exercises. <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**Ticket out Door:** Read the answer provided by other groups.
 * Friday** **2/5/10**
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Do Now: **
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Assignment: **


 * Thursday 2/4/10

Do Now: Read:** Read the front and back of the handout titled, **Fewer High School Students Taking Computer Science Classes**.

Write on paper or type in Microsoft Word:** 1. Summary of article 2. How this relates to you 3. What you would say in a blog post.
 * __Assignment:__

Turn in your hand-written paper or save your Word document as CSclassesArticle.doc and upload it to your Gaggle digital locker. Read the Summary and Questions and Answers on pages 66 to 68 in the Dawson paper back textbook. Think - Pair - Share: Think about the discussion questions on page 68 and jot some answers on paper. Talk it over with a couple of students in the class to expand your thinking and answers. Edit http://hangencpp.wikispaces.com/ with your groups answers. <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">**Ticket out Door:** Read the answer provided by other groups.
 * <span style="background-color: #800000; color: #ffff00; font-family: Arial,Helvetica,sans-serif;">__Ticket out the Door:__ **
 * Wednesday 2/3/10**
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Do Now: **
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Assignment: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Do Now: ** In general what is a common use of a switch case structure? <span style="color: #000000; font-family: Arial,Helvetica,sans-serif;">Program: **ShipPigeon.cpp** Directions in your white notebook. Program: **PlanetWeight.cpp** Directions are in the green and gold textbook pages 134 and 135 Project 7-4.
 * Thursday 1/28/10 and Monday, Tuesday 2/1,2/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Assignment: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Do Now: ** Finish paper and pencil assignment <span style="color: #000000; font-family: Arial,Helvetica,sans-serif;">Program: **Shipping.cpp** Directions in your white notebook.
 * Wednesday 1/27/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Assignment: **

<span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Do Now: ** Read: Switch Structure Notes & Chapter 7 Summary (in white notebook) Paper and Pencil: Questions on Switch Structure Notes Ch. 7 Summary (in white notebook) Refer to Chapter 7 in the Green and Gold textbook.
 * Monday & Tuesday 1/25, 26/10
 * <span style="color: #000000; font-family: 'Comic Sans MS',cursive;">Assignment: **

First marking period assignment at QT1 page. Second marking period assignment at QT2.