Variable Assignment(s)
You must do at least 2 programs that incorporate variables:
- For ideas: check out the math related examples that we discussed with the flowchart assignment.
- link to the page under Introduction to programming < Thinking Like A Computer > Part 3: Flowcharts:
- A good one to try: (If not doing this for your later game assignment) Number Guessing Game: Have user try to guess a number that the program has randomly generated within a specific range (i.e. between 1 and 100 or between 1 and 1000). The program should provide clues as to too high, too low, correct. Program should keep track of the number of guesses and should include an opportunity to play the game again. Think of other ways to complicate this program - levels of difficulty, high score board, etc.
- If you are struggling, try doing or following the projects I have done below. They are ones I have provided examples for. As you will basically redoing some of the work I have already done, for full marks, I would like to see you do at least one that isn't from this list. If not try to add some variations to theses.
- Marks Program: Have user enter name and 3 quiz marks (Quiz 1 out of 20, Quiz 2 out of 40, and Quiz 3 out of 30). Program should then calculate and display the current mark. (Consider whether it is based on total points or on an average of the 3 marks)
- Cookie Monster: Have the user enter how many dozens of cookies they have (between 4 and 10 dozen) and how many friends they have (between - and 15). Then have the program calculate how many whole cookies each person gets, keeping in mind that the Cookie Monster gets the rest.