QT4

=Computer Programming II, C++, CS702, QT4, Period 8= //__Objective__: Work with programmer defined functions effectively.//  Get your binder.  __Program__: **ReduceFractions.cpp** in binder  Upload to your Gaggle digital locker.
 * Monday June 6, 2011**

//__Objective__: Work with programmer defined functions effectively.//  __Program__: **Proto1.cpp** in binder  __Program__: **CtoF.cpp** in binder Finish Chapter 5 programs.  Print out according to previous instructions. Upload to your Gaggle digital locker.
 * Friday June 3, 2011**

//__Objectives__: Write new functions.// //Accept values into your new functins through parameters.// //Return information from you new functions through return values.// //Work with global variables and constants.// //Overload functions.// //Use inline functions.// //__Goal__: Chapter 5//  __Read__: **Chapter 5** in the Dawson paperback book.  __Program__: **Instructions.cpp** __Program__: **YesNo.cpp** __Program__: **Scoping.cpp** __Program__: **GlobalReach.cpp** __Program__: **GiveMeNumber.cpp** __Program__: **Triple.cpp** __Program__: **TakingDamage.cpp** __Program__: **MadLib.cpp**  Upload to your Gaggle digital locker.
 * Thursday May 26 - Thursday June 2, 2011**

//__Objective__: Use library algorithms to work with groups of elements. Use vectors and vector functions.// //__Goal__: Review Chapter 4//  __Paper and Pencil__: **Ch 4: The Standard Template Library** (Fill in the blank handout)  __Paper and Pencil__: **Exercises** 2 and 3 on page 127. Put this on the back of the handout. __Program__: **GameTitles.cpp** Continue working on this.  Turn in papers.
 * Wednesday May 25, 2011**

__Objective__: Use library algorithms to work with groups of elements. Use vectors and vector functions. __Goal__: Review Chapter 4  __Read__: Read **Summary and Questions and Answers** on pages 124 to 126  __Paper and Pencil__: **Discussion Questions** on page 126
 * Monday & Tuesday May 23 & 24, 2011**

__Program__: **GameTitles.cpp**  Turn in **Discussion Questions**. Save and upload **GameTitles.cpp** to your Gaggle digital locker. Print the source code and output showing thorough testing.
 * Exercise** 1 on page 127. Write a program using vectors and iterators that allows a user to maintain a list of his or her favorite games. The program should allow the user to list all game titles, add a game title, and remove a game title.

//__Objective__: Use library algorithms to work with groups of elements. Plan programs with pseudo code.// __Finish Program__: **WordScramble.cpp** Directions in binder. __Question__: Include this in your Word document and printout. Include an explanation of the thinking process you went through while doing this program. What thinking, planning, and coding strategies did you use?
 * Thursday & Friday May 19, 20 2011**

Discuss pseudo code. __Read__: Read pages 116 - 125 __Program__: **Hangman.cpp** P. 122

Save and upload to your Gaggle digital locker.

//__Objective__: Use library algorithms to work with groups of elements.// __Read__: Read page 116 __Program__: **WordScramble.cpp** Directions in binder. __Question__: Include this in your Word document and printout. Include an explanation of the thinking process you went through while doing this program. What thinking, planning, and coding strategies did you use?
 * Wednesday May 18, 2011**

Save and upload to your Gaggle digital locker. Put **WordScramble.cpp**, its output, and your explanation in a Word document and print it.

//__Objective__: Use library algorithms to work with groups of elements.// __Read__: Read pages 112 to 116 __Program__: **HighScores.cpp** P. 113 - 114 __Questions__: Include the answer to these questions on your printout. 1. List 2 examples of common tasks that algorithms can be used for. 2. Can the same algorithm work with elements of different container types? 3. What line of code contains the compiler directive with the necessary header file for using standard library algorithms? 4. What does srand(time(0)); do? 5. What is different about the elements in the vector scores before and after this line of code? random_shuffle(scores.begin, scores.end); 6. What does the merge algorithm do? 7. What must be done to insure that all the scores have spots in the new vector, allScores? Save and upload to your Gaggle digital locker. Print HighScores.cpp, its output, and the answer to the questions 1-7.
 * Tuesday May 17, 2011**

//__Objective__: Pass parameters. Use do while loops (repeat until) effectively.// //Share information with different sprites. Use repeat until effectively. Trouble-shooting. Critical thinking. Decide when it is appropriate to use specific structures.// 1. What structure in C++ is comparable to the repeat 10 that was used in the bee script? 2. Explain what the repeat 10 does in the bee script. __Scratch Program__: **BeeSting.sb** 3 pages of directions provided. __Your Challenge__: **Create the scripts for the flower**. Make it change to the costume with the yellow center when the bee pollinates it. 3. Explain the thinking process you used to create the script for the flower.
 * Monday May 16, 2011**

//__Objective__: Pass parameters. Use do while loops (repeat until) effectively.// 1. What does a bee do with flowers? 2. What is a person's reaction when being stung by a bee? 2. What happens to a bee after it stings someone? 3. Where is a bee's stinger? __Scratch Program__: **BeeSting.sb** 3 pages of directions provided. __Your Challenge__: Create the scripts for the flower. Make it change to the costume with the yellow center when the bee pollinates it. 4. Explain why you needed to use repeat until instead of forever if. 5. Repeat until in Scratch is comparable to what in C++?
 * Friday May 13, 2011**

//__Objective__: Use iterators to move through sequences.// Put **HerosInventory2.cpp** source code, output, and the ToD questions from Friday in a Word document and print it. __Read__: **Chapter 4** in the black paperback Dawson textbook, pages 105- 112. __Program__: **HerosInventory3.cpp** P. 106 Save and upload to Gaggle digital locker.
 * Monday & Tuesday May 9 & 10, 2011**

//__Objective__: Use vectors to work with sequences of values.// //__Objective__: Use vector member functions to manipulate sequence elements.// __Analyze__: **HerosInventory.cpp** on page 84 of the Dawson book. __Read__: **Chapter 4** in the black paperback Dawson textbook, pages 99 - 105. __Program__: **HerosInventory2.cpp** P. 101 1. What is the compiler directive that specifies what header file to use with vectors. 2. Write the declaration of the vector in this program. 3. What member function adds a new element to the end of a vector? 4. What programming structure is used to output hero's items? 5. What function indicates how many items are in the vector? 6. How can you refer to one member of the vector element in this program? 7. Explain the difference between the push_back and the pop_back member functions. 8. Explain the difference between the clear member function and the empty member function. Save and upload to Gaggle digital locker.
 * Friday May 6, 2011**
 * Include these on your printout for HerosInventory2.cpp.**

//Objective: Use ASCII codes and for loops effectively.// Look over the ASCII codes sheet in your binder. __Program__: **Alphabet.cpp**
 * Thursday May 5, 2011**

Save and upload to Gaggle digital locker.

//Objective: Use the string object effectively.// Demonstrate your WasteChalk.cpp program. __Program__: **CharacterCountB.cpp**
 * Wednesday May 4, 2011**

Save and upload to Gaggle digital locker.

//Objective: Use the string object effectively.// @http://www.addletters.com/bart-simpson-generator.htm __Program__: **WasteChalk.cpp** Create the WasteChalk.cpp program based on the output. Do a part and test it. Do another part and test it, and so on. Follow the standard procedure for putting this in a Word document and testing it.
 * Friday April 29 - Tuesday May 3, 2011**

//Objective: Use parameters effectively.// http://scratch.mit.edu/projects/Klovira/109633/Klovira/109633
 * Thursday - Thursday April 21-28, 2011**

__Scratch Program__: **Egg8.sb**

Save and upload to Gaggle digital locker.

//Objective: Use the string object effectively.// @http://www.addletters.com/bart-simpson-generator.htm __Program__: **WasteChalk.cpp** Create the WasteChalk.cpp program based on the output. Do a part and test it. Do another part and test it, and so on. Follow the standard procedure for putting this in a Word document and testing it.
 * Wednesday April 20, 2011**

//Objective: Use the string object effectively.// Discuss fire drill procedures.
 * Tuesday April 19, 2011**

__Program__: **StringInputgetline.cpp**

Follow the standard procedure for putting this in a Word document and testing it. Print on one page if possible.

//Objective: Use character variables and characters effectively.// __Paper and Pencil__: Section 6.1 Questions 1-6, page 97 in the green and gold textbook.
 * Wednesday - Friday April 13 - 15, 2011**

__Program__: Problem 6.1.1 **Betsy.cpp** page 97 in green and gold textbook __Program__: Problem 6.1.2 **Hello.cpp** page 97 in green and gold textbook

Follow the standard procedure for putting these in a Word document and testing them. Print on one page if possible.

//Objective: Use character variables and characters effectively.// __Read__: **Chapter 6: Strings and Screen I/O** pages 91 - 107 in the green and gold textbook.
 * Monday & Tuesday April 11 & 12, 2011**

__Paper and Pencil__: **cin.get** and **cin.ignore** questions __Program__: **InLine.cpp**

Follow the standard procedure for putting this in a Word document and testing it. Print.

//Objective: Use string functions effectively.// What string functions exist in Scratch and where do you find them?
 * Wednesday - Friday April 6-8, 2011**

Quagmire isn't just a cartoon character's name. @http://www.learnersdictionary.com/search/quagmire __Try out__: **WordGame.sb** without looking at the scripts. This would be a word game for young children. __Scratch Program__: **WordGame.sb** Write the scripts that would produce this game. Show me what you have so far.

//Objective: Use the fundamental counting principal of probability, nested for loops, and ASCII codes to create a program using letters of the alphabet.// New seating chart! __Save to the desktop__: **Possible.cpp** from your Gaggle digital locker. Open your notebook to the directions for **Possible.cpp**.
 * Monday & Tuesday April 4 & 5, 2011**

__Go over__: **Possible.cpp** __Program__: **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. Follow the standard procedure for putting this in a Word document and testing it. Print.