Warm-up: Dry Run DIV / MOD 2nd If Then Program

Slides:



Advertisements
Similar presentations
Mod arithmetic.
Advertisements

1. ( ) ÷ 1 = (A) 1818 (B) 1414 (C) 4 15 (D) 1212 (E) ( ) ÷ 1 = ÷ 1 = = ( ) ÷ 1 =
Identify and state the value of a penny, nickel, dime, quarter Level 1 CLICK HERE TO START LEVEL 1.
In Class Exercises. TV  Think about your television as an object.  You send messages to it using the remote control. What messages can you send?  What.
Lets Count Money!!! Kelly Goolsby. Content Area: Math Grade Level: 2nd Summary: The purpose of this instructional power point is to teach students how.
2nd grade Math Lesson 2.MD.8. Solve word problems involving dollar bills, quarters, dimes, nickels, and pennies, using $ and ¢ symbols appropriately.
Math Review Show each amount using the fewest number of coins. 98¢ pennies nickels dimes quarters 1.
Warm Up 1)Find an angle between 0° and 360° that is coterminal with 1190°. 2)Convert 45 degrees to radians.
Synthetic Division. This method is used to divide polynomials, one of which is a binomial of degree one.
Copyright 1999 by Larry Fuhrer. Pascal Programming Getting Started...
Jeopardy Functions Review. Solve equations 100 ANSWER.
Money Counting By: Aleela Bovell 2 nd Grade Math LETS BEGIN!
Basic Money Skills Basic Consumer Math Lesson 1 Introduction Mrs. Stack.
$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$ $$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$$
Counting Coins. The Basics Quarter 25 cents Dime 10 cents.
Money By Shelly Hodges Let’s learn about money!
2 nd Quarter Math Review Click here to Begin = ? Add the numbers below. Choose the correct answer
Let’s Learn About Money!
Name the United States Coins Count the Pennies 10 ¢
MATH AND MONEY.
CSE 20: Discrete Mathematics for Computer Science Prof. Shachar Lovett.
Algebraic thinking Math 123. Warm-up Solve the following equations: 2a - 13 = 15a 3b – 8 = 4b – 4c = 15.
 1. The points whose coordinates are (3,1), (5,-1), and (7,-3) all lie on the same line. What could be the coordinates of another point on that line?
The Importance of Counting Coins. Coins in everyday life  How important is being able to count coins?  What are coins used for?  When and how often.
Computer Science I: Understand how to evaluate expressions with DIV and MOD Random Numbers Reading random code Writing random code Odds/evens/…
Math Challenge 12/1 Solve the following = ____ = _____ = _____.
Algebra 1 Section 6.3 Solve and graph compound inequalities A compound inequality is form by combing two inequalities. A new born calf should weigh greater.
3-3 I WILL… Divide Decimals!!! Warm Up Divide ÷ ÷ ÷ (–2) ÷ 21.
Grade 8: Linear Functions
3x + 2 6x3 - 5x2 – 12x – 4 2x2 – 3x – 2 6x3 + 4x2 -9x2 – 12x -9x2 – 6x
Objective The learner will solve problems using formulas
k-2 Lesson d: kids as coins Coin Signs
Money Concept Assessment Bank
Assignment statement and Arithmetic operation 2
Temperature: Comparing degrees Celsius (C) and degrees Fahrenheit (F)
Program Options: 10 Minutes online
CMP 131 Introduction to Computer Programming
Program options Write a program for one of the following
Warm Up Find an angle between 0° and 360° that is coterminal with 1190°.
Review Dry Run Taking Names Online time Math is Good
Name the United States Coins
Dry run Fix Random Numbers
More Maths Programming Guides.
Program Options: 10 Minutes online
Repeat Day2 Dry Run Second Repeat Program
Tests of Divisibility 1 - All integers can be divided by 1
Computer Science 1 Warm-up: True/False Dry Run
Computer Science
What do you do when you don’t know how to get started.
Lesson Quizzes Standard Lesson Quiz
Computer Science 1 Online time for Graphics Program Random review
How can you make a guessing game?
Computer Science II Second With files.
Computer Science 2 Take out a piece of paper for the following dry runs. Label It Recursive Dry Runs 4/12/2018. It will be turned in when completed
Computer Science 2 More Trees.
Computer Science 1 while
Computer Science 1 For..do loop Dry Run Take notes on the For loop
How can you make a guessing game?
Computer Science
Warm-up: True/False Dry Run DIV / MOD 2nd If Then Program
FORMULAS.
Computer Science I: Get out your notes.
Program options Write a program for one of the following
Dry Run Fix it Write a program
Ask A Cricket The Temperature
Computer Science 1 while
Dry Run Fix it Write a program
Money Week 31 April 3 , 2019.
Computer Science And he made a molten sea, ten cubits from the one brim to the other: it was round all about, and his height was five cubits: and.
COMPUTING.
Presentation transcript:

Warm-up: Dry Run DIV / MOD 2nd If Then Program Computer Science 1 Warm-up: Dry Run DIV / MOD 2nd If Then Program

Learning Targets Be able to Dry Run a program that uses if Understand how to use DIV and MOD. Write a program Review for Thursday’s quiz by completing a practice quiz.

Dry Run the following program ifOne; var a,b:integer; begin a:= 10; if a>b then a:= a - 4; b:=b+1; end; writeln(a,b); readln; end.

DIV Pascal’s Integer Division How can you get an integer result when you divide? For example, if you divide 5 by 2 what do you think the answer would be? What about the remainder. Pascal has math operations for finding the result of integer division and the remainder of integer division.

DIV and MOD DIV is used to find the result of integer division For example X := 13 DIV 5; X:= 21 DIV 10; X:= 20 – 8 DIV 3; x:= 1 DIV 2; MOD is used to find the remainder of integer division X := 13 MOD 5; X:= 21 MOD 10; X:= 20 – 8 MOD 3; x:= 1 MOD 2;

DIV and MOD samples Ans:=23 DIV 10; Ans:= 14 DIV 4; Ans:= 52 DIV 5; Ans:= 23 MOD 10; Ans:= 14 MOD 4; Ans:= 52 MOD 5; Ans:= 14 MOD 3; Ans:= 8 MOD 9; Ans:= 5 MOD 10; Ans:= 4.13 MOD 2;

Program options. Input: The amount of change (Integer value, like 66 cents) Output: The least amount of coins it takes to make the change: For 66 cents 2 Quarter(s) 1 Dime(s) 1 Nickel(s) 1 Penny/Pennies Input: The number of Chirps per minute for a cricket. Output: The outside temperature in Fahrenheit and give an appropriate statement if the temperature is greater than 90 degrees F. Using his equation, called Dolbear's Law, you can determine the approximate temperature in Fahrenheit, based on the number of cricket chirps you hear in one minute. Dolbear's Law: T = 50+[(N-40)/4]  T = temperature  N = number of chirps per minute Push: Add other comments for different temperatures, The above equation is for field crickets, look up equations for different types of crickets.