Computer Science 1 Dice Project.

Slides:



Advertisements
Similar presentations
This is the online version of the game of craps. It is a type of simulation game. It’s as though you’re playing on the real table. Craps is played in most.
Advertisements

EGR 141 Computer Problem Solving in Engineering and Computer Science
The game of Craps Rules of play: 1. Played with two dice (six faces to a die – numbers 1-6 per face) 2. Sequence of betting rounds (or just rounds) 3.
Craps!. Example: A Game of Chance Craps simulator Rules – Roll two dice 7 or 11 on first throw, player wins 2, 3, or 12 on first throw, player loses 4,
Mr. Kemp 6 th Grade. What is Keyboarding? 45 days long We will cover the following within this class: Correct Posture Correct Keystrokes Typing Club
ABI Gradebook Training We are all in this together!
Introduction to Arrays. definitions and things to consider… This presentation is designed to give a simple demonstration of array and object visualizations.
Class Usability Experience User slides are in BLUE.
Writing JavaScript Functions. Goals By the end of this unit, you should understand … How to breakdown applications into individual, re-usable modules.
More on Logic Today we look at the for loop and then put all of this together to look at some more complex forms of logic that a program will need The.
Iteration. Iteration: Review  If you wanted to display all the numbers from 1 to 1000, you wouldn’t want to do this, would you? Start display 1 display.
© The McGraw-Hill Companies, 2006 Chapter 3 Iteration.
Computer Science I: Understand how to evaluate expressions with DIV and MOD Random Numbers Reading random code Writing random code Odds/evens/…
Creating Your Own Online Classroom MOODLE. Welcome Amy Basket – 17 years with Bay City Public Schools – Gifted and Talented Program – Volunteer Program.
Compile your monthly P-Card Packet 1,2,3 For in depth screenshots and details on Step 1 click here 1.Open your transactions for the Current Billing Cycle.
Farkle is a game of chance You need: a) 6 dice b) A good head for numbers c) A lot of luck The object of the game is to accumulate 1,000 points first!
Local Government Corporation Resource 2016 NextGen Trustee Year End.
RUNNING GFU REPORTS Let’s Get Started!. VP’s: This is what it was.
ICS 3UI - Introduction to Computer Science
By: Jordan Simon Mike Norman Charles Slack
Preparation of ULAB EVAL part C
Understanding Why You Do What You Do
Lecture 11.
Thursday, March 30, 2017 Day 2 Agenda Science Notebook
ENEE150 Discussion 02 Section 0101 Adam Wang.
Stem and Leaf Plot.
Lecture 10.
JavaScript Functions.
Little work is accurate
Object of the game Yahtzee Large straight Small straight Full house
Probability of casino games
Information about all the ULABs left
Welcome to the Nobel Music Department
Introduction to Computer Programming
Escape sequences: Practice using the escape sequences on the code below to see what happens. Try this next code to help you understand the last two sequences.
Truth tables: Ways to organize results of Boolean expressions.
Computer Science 1 Dice Project.
HOW TO CREATE A CLASS Steps:
Use Model Drawing Procedure in Four-Step Process
Dry run Fix Random Numbers
Mrs. Young’s School Letter SGMS School Year
Truth tables: Ways to organize results of Boolean expressions.
Java Lessons 28 – 32 Mr. Kalmes.
Object of the game Yahtzee Large straight Small straight Full house
Preparation of ULAB EVAL part C
Python 19 Mr. Husch.
Computer Science 2 Tally Arrays 2/4/2016.
Truth tables: Ways to organize results of Boolean expressions.
Flowcharts and Pseudo Code
A First Grade Number Routine
Learning Targets Career: Discover strengths/experiences
Computer Science 1 while
Agenda Warmup Lesson 1.9 (random #s, Boolean variables, etc)
Computer Science 1 4/4/2016.
Computer Science I: Get out your notes.
Probability True or False?.
Fun… Tree Diagrams… Probability.
Chapter 7 Empowering Programs with Math
Relations And Functions.
Python 19 Mr. Husch.
Computer Science 1 while
What does this mean? Drawing Conclusions.
Probability – Experimental & Expectation – Activity A
A bit of Review Review, Dry Run, Program.
Object of the game Yahtzee Large straight Small straight Full house
Year 8 Computer Science Digital Portfolio
Object of the game Yahtzee Large straight Small straight Full house
Agenda Warmup Lesson 1.9 (random #s, Boolean variables, etc)
HOW TO PLAY PLAY.
HOW TO PLAY PLAY.
Presentation transcript:

Computer Science 1 Dice Project

Learning Objectives Be able to develop a fairly large scale program meeting the needs of a client. Demonstrate how to understand the questions, develop a pseudo code, test the pseudo code, translate to code and communicate with the client throughout the development of the project.

Project West High Lottery has decided to create an ‘online fund raising’ service through games of chance. Below are the descriptions of the games that must be included and how the results must be formatted in order to get the most out of our valued donors.

Game 1 Friends Involved in Enabling Lots of Donations (or Field for short) Rules: Roll a pair of six sided dice If the donor rolls a 2 or a 12, they win twice their bet. If the donor rolls a 3, 4, 9, 10, or 11, they win the amount they bet. If they roll anything else, they lose their bet.

Game 2 Creative Raising of Additional Phinancial Securities (or Craps for short) Rules: Roll a pair of six sided dice If the donor rolls a 2, 3, or 12 on the first roll, they lose. If the donor rolls a 7 or an 11 on the first roll, they win. If the donor rolls anything else (4, 5, 6, 8, 9, 10) then this first roll is saved as the POINT and the game changes a little, but continues Now the donor continues to roll until they roll… a 7 and lose or the POINT and win

Required stuff Include a limit of $1000 bet. (Why?) No negative bets Do not let the user bet more money than they have. Create a chart like Hands on. This is for the Parents Club and more details are coming.

Extensions: Put in additional games Include giving gifts if they have played for a long period of time. Add graphics/animations Make it educational …

Due Dates and Required Parts Hands on: Thursday 11/29 (10 points) Thursday at the beginning of the period -1 point if late Pseudo code: Monday 12/3 (20 points) By the end of the period -2 points if late Dry Run: Tuesday 12/4 (10 points) Beginning of the period Code: Monday 12/10 (50 points) Monday at the end of the period -5 points if late

Partial Sample Hands On For your hands-on you will need to demonstrate every first roll for each game Starting Balance Game Bet Roll Win/loss New Balance $1000.00 Field $100.00 2 $200.00 $1200.00 $1200.00 Field $150.00 10 $150.00 $1350.00 $1350.00 Field $100.00 7 $-100.00 $1250.00 $1250.00 Craps $100.00 2 $-100.00 $1150.00 $1150.00 Craps $100.00 7 $100.00 $1250.00 $1250.00 Craps $100.00 6 10 2 6 $100.00 $1350.00 $1350.00 Craps $500.00 10 6 7 $-500.00 $850.00 You entered with $1000 and you left with $850. Thank you for your $150.00 donation. This becomes the point. Don’t forget the closing comments. You will need to have different comments based on their winnings or losses.

Pseudo Code Psample (20 points) … Get the users choice (Craps, Field, Quit) While they did not chose quit If they chose Field Get the donors bet Until it is a valid bet (not > $1000, not negative, not more than they have) Roll the dice If the roll is a 2 or a 12 Winloss = twice the bet NewBalance = Balance + winloss Show Balance, ‘Field’, bet, roll, Winlosss, NewBalance Balance = newbalance If the roll is a … For your Pseudo Code it will need to handle all possibilities.

Dry Run (10 Points) This is where you test your Pseudo-code. It will look like the hands on except it is testing the pseudo code… Use the pseudo code to determine what is shown It will only need to go through each path (win. loss, double win, …,) not every first roll. Variables Money Game Bet… But in showing the chart, it needs to be just like the client wants. For getting input from the user you can use shorthand……. Screen ………. Starting Balance Game Bet Roll Win/loss Amt New Balance $1000.00 Field $100.00 2 $200.00 $1200.00 …

“All for one, two for five, first to ten or last alive….” Code (50 points) This is the program you will turn in. Be smart and lazy when implementing!! First write and test the menus Then Field be win Then field loss … Always checking between … “All for one, two for five, first to ten or last alive….”

After you complete and check a section, bring it back to Mr After you complete and check a section, bring it back to Mr. Smith for evaluation. Grading Sheet

Due Dates and Required Parts Hands on: Thursday 11/29 (10 points) Thursday at the beginning of the period -1 point if late Pseudo code: Monday 12/3 (20 points) By the end of the period -2 points if late Dry Run: Tuesday 12/4 (10 points) Beginning of the period Code: Monday 12/10 (50 points) Monday at the end of the period -5 points if late