GCSE Computing Working with numbers. Challenge ‘Crimson Mystical Mages’ is a fantasy role playing board game. You need to create an electronic program.

Slides:



Advertisements
Similar presentations
EGR 141 Computer Problem Solving in Engineering and Computer Science
Advertisements

Random Numbers In today’s lesson we will look at: why we might want a random number whether they really are random how to create and scale random numbers.
Dice Task Task 1Task 2Task 3Task 4 Task 5Task 6Task 7Task 8 NC Level 3 to 6.
Dice Games & Probabilities. Thermo & Stat Mech - Spring 2006 Class 16 Dice Games l One die has 6 faces. So, the probabilities associated with a dice game.
EXAMPLE 1 Construct a probability distribution
Calculating Probabilities Teach GCSE Maths What is the probability that the bus is on time ?
VK Dice By: Kenny Gutierrez, Vyvy Pham Mentors: Sarah Eichhorn, Robert Campbell.
Two way tables There are 125 children in Year 6. 52% of them are girls. 20% of girls do not play football. Five times as many boys play as do not play.
Monopoly Game Example Mutually Exclusive.
EXAMPLE 1 Construct a probability distribution Let X be a random variable that represents the sum when two six-sided dice are rolled. Make a table and.
Horse race © Horse race: rules 1.Each player chooses a horse and puts it into a stall. Write your name next to the.
Equations Stages Obtain Resources Set a Goal Qualify Resources until a Challenge is made or Force Out is called Resolve Challenge or Force Out Score the.
Functions and methods A method is a function that is a member of a class FCL(Framework Class Library) provides a rich collection of classes and methods.
Section 3.6 BUILT-IN FUNCTIONS involving numbers & strings.
Rapid Recall Activities. Retention of facts is key with the New Curriculum Rolling Dice: Rolling a 10-sided dice and making number bonds to 10 Adding.
Check it out! : Simple Random Sampling. Players of a dice game roll five dice and earn points according to the combinations of numbers they roll.
MONOPOLY MODERN GAME.
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,
Objective How to solve Integer problems
MOM! Phineas and Ferb are … Aims:
Copyright©amberpasillas2010. For Learning to Happen! Please pay close attention to this lesson. This lesson is very short, only 2 slides ! My goal is.
In this chapter we introduce the idea of what it means for something to be truly random. We also investigate techniques for simulating randomness.
Probability of Compound Events
7.4 The Mean The means were 2.62 and – What does this say in relation to the problem? What was the theoretical expectation? – This is also call the.
Probability Distributions
Created By: Kevin Jiang, Cullen Wong, Stephen Halter.
2.2 Adding Integers Use a number line to help visualize the addition of integers.
Geometric Distributions Consider a game of monopoly.
Divide class into groups of 4-6 players. Estuary Survival game flowchart.
2 Digit Divisors. 3,521 ÷ 26 = = 26 x = 26 x 3 Click the squirrel for a video on repeated multiplication.
Four in a Line activities. "Four in a Line" games These games are enormously adaptable. They can be used for a vast range of mathematical topics, and.
© Copyright 1992–2004 by Deitel & Associates, Inc. and Pearson Education Inc. All Rights Reserved. Functions (Header files and Library Functions) Outline.
Activity 1: Play Fours Play in pairs Each player has a 3 by 3 grid Take turns to roll 2 dice Calculate the total- each spot is worth 4 points Write your.
Discrete Distributions. Random Variable - A numerical variable whose value depends on the outcome of a chance experiment.
 Construct a stem and leaf plot: 15, 4, 28, 23, 21, 9, 8, 11, 15, 9 1 leaf 0 stem 2 4, 8, 9, 9 1, 5, 5 1,3, 8.
WOULD YOU PLAY THIS GAME? Roll a dice, and win $1000 dollars if you roll a 6.
Random UNPREDICTABLE NUMBERS. A FEW APPLICATIONS THAT USE RANDOM…. Predictions for life expectance used in insurance Business simulations Games (Give.
Max – a game with two dice. Preparations You need a dice cup and two dice. There‘s no limit to the number of players. You just have to be the best bluffer.
Binomial Probability Section Starter Here’s a game you will like: Let’s bet a dollar on this proposition: I will roll a fair die once. If.
Random Numbers Random numbers are extremely useful: especially for games, and also for calculating experimental probabilities. Formula for generating random.
From Wikipedia: “Parametric statistics is a branch of statistics that assumes (that) data come from a type of probability distribution and makes inferences.
PIG GAME. MATERIALS  Dices  Scoring pad or sheets Player 1Player 2 Roll
Computer Science I: Understand how to evaluate expressions with DIV and MOD Random Numbers Reading random code Writing random code Odds/evens/…
CHAPTER 4 Negative Numbers. ADDITION AND SUBTRACTION USING NEGATIVE NUMBERS A number line is very useful when you have to do additions or subtractions.
Playing with Dice 2/20/2016Copyright © 2010 … REMTECH, inc … All Rights Reserved1 ● Rolling a Single Die – 6 possible outcomes (1 – 6) ● Rolling Dice is.
int [] scores = new int [10];
Expected Value Standards: MM1D2. Students will use the basic laws of probability. d. Use expected value to predict outcomes. Lesson Essential Question:
Objective of the lesson Use Blockly to make a dice for Snakes and Ladders All of you will: – Make an image which displays when you press a button Most.
Dice Games & Probabilities
Rapid Recall Activities
Using Base Ten Blocks to Make Numbers to 100
Adding and Subtracting Integers is like …
LO: to recognise < > and = symbols
1-7 Adding and Subtracting Integers
Physics-based simulation for visual computing applications
Truth tables: Ways to organize results of Boolean expressions.
TRICKS & TREATS Each team rolls the die, lowest number goes first.
What makes a good mathematical game?
Truth tables: Ways to organize results of Boolean expressions.
Games Workshop.
3rd/4th grade Family Math Night Games
Probability and Simulation
Expected Value Lesson Essential Question:
PICK 6 Game Board

Complete the sample space diagram on your whiteboards
Homework Due Friday.
int [] scores = new int [10];
Homework Due Friday.
Integers Blast Off
Presentation transcript:

GCSE Computing Working with numbers

Challenge ‘Crimson Mystical Mages’ is a fantasy role playing board game. You need to create an electronic program to calculate powers for players.

Challenge A player gets powers by rolling two dice. 1 is a 4 sided dice, the other is a 12 sided dice. The person’s power is the score of the 12 sided dice divided by the score on the 4 sided dice PLUS 10.

Challenge You need to create a program which calculates a person’s power score It must simulate the throwing of both dice Then calculate the score and tell the player

Challenge There is some help..... Visual Basic does the dice job for you.....

Random Numbers RND is a function in visual basic It randomly generates a number greater than 0 but smaller than 1 e.g. 0.2, 0.91, 0.456,

Random Numbers Dim Result as integer To create a number between 1 and Result = Int((6 * Rnd) + 1)

Combat When there is an encounter between two characters a battle occurs! the outcome is determined by the following process:

Combat The differences between the power score for the two characters is calculated This difference is divided by 2 and then rounded down to create a ‘strength modifier’ Then each player rolls a 6 sided dice

Combat Whoever has the highest score gets the strength score added to their power score. The loser gets the strength score subtracted from their power score.