Review Dry Run A Little More Math Fix it Online time

Slides:



Advertisements
Similar presentations
Mr. Gs Problem Solving Guidelines. Step #1 Identify and write the variables given in the problem. Ex:V f = 10 m/s V o = 0 t = 2 sec.
Advertisements

Write a program step by step. Step 1: Problem definition. Given the coordinate of two points in 2-D space, compute and print their straight distance.
Program Design. Objectives Students should understand the basic steps in the programming process. Students should understand the need for good design.
Compound Operators 03/07/11. More Operators, First Section 4.4.
6 Steps of the Programming Process
Agenda Review Compiling Review Data Types Integer Division Composition C++ Mathematical Functions User Input Reading: , 8.11 Homework #3.
Pascal language Slides of Omar Al-Nahal. Components of Pascal Language Components of Pascal Language 1. Pascal Character set: - English Letters. - Decimal.
Introduction to Programming with RAPTOR
Variables on Both Sides. Visual 5x + 6 = 3x + 12.
C++ Basics C++ is a high-level, general purpose, object-oriented programming language.
Agenda 9/14/2015 (43 min)  Prelude (15 min)  Vocab (20 min)  Synthesis (8 min)
Variables. Todays Lesson  In todays lesson you are going to:  Learn to use variables  Learn to ask for user input  Learn to save the users response.
Programming, an introduction to Pascal
Going Green Initiatives in AP Computer Science A (Mr. Smith’s Classroom)
An exponential equation is one in which a variable occurs in the exponent. An exponential equation in which each side can be expressed in terms of the.
Program Options: 10 Minutes online Write a program that will display your home address as it would on an envelope. –First Name Last Name –Address –City,
Computer Science I: Understand how to evaluate expressions with DIV and MOD Random Numbers Reading random code Writing random code Odds/evens/…
Please CLOSE YOUR LAPTOPS, and turn off and put away your cell phones, and get out your note- taking materials.
8/26 Reminders: Supplies Due: Canvas (Online Learning) Due:
Computer Science 1 9/10/2014 Review Dry Run Math in Pascal How do you start, when you don’t know where to start?
15.1 More About High-Level Programming Languages Syntax and Semantics Each programming language contains its own rules for both syntax and semantics. Syntax.
CLOSE Please YOUR LAPTOPS, and get out your note-taking materials.
Cornell Notes for Math Process Problem Use distributive property
Lesson 4 – Glowing pendulum
Week 2: QUIZ RETAKE LOG INTO YOUR PERSONAL FOLDER NOW.
Program Options: 10 Minutes online
Program options Write a program for one of the following
VISUAL BASIC .NET Chapter 6 Assignment Sheet
MATH 2160 Pascal’s Triangle.
Solve a system of linear equation in two variables
Computer Science II First With files.
Computer Science II First With files.
Objective #1 To be able to factor equations by finding the Greatest Common Factor (GCF)
Computer Science 1 Dice Project.
Review Dry Run Taking Names Online time Math is Good
Computer Science 1 Get out your notebook
Dry run Fix Random Numbers
Program Options: 10 Minutes online
Robotics Programming 9/18/2015.
Python 19 Mr. Husch.
Robotics Programming 9/18/2015.
Computer Science 1 Warm-up: True/False Dry Run
Standard Form Quadratic Equation
Computer Science 2 Tally Arrays 2/4/2016.
What do you do when you don’t know how to get started.
Computer Science 1 Online time for Graphics Program Random review
Solving Equations with Variables on Both Sides
How can you make a guessing game?
Solving Equations with Variables on Both Sides
Computer Science 2 More Trees.
Computer Science Procedures Day 2.
Computer Science 1 while
Computer Science 1 For..do loop Dry Run Take notes on the For loop
Warm-up: Dry Run DIV / MOD 2nd If Then Program
How can you make a guessing game?
Computer Science 1 Dice Project.
Computer Science
Notes Over 1.3 It’s time to stop “daydreaming”
Computer Science 1 4/4/2016.
Computer Science I: Get out your notes.
Python 19 Mr. Husch.
Program options Write a program for one of the following
Dry Run Fix it Write a program
Expressions & Equations Jeopardy
Computer Science 1 while
Computer Science 1 Get out your notebook
Computer Science 1 Get out your notebook
Dry Run Fix it Write a program
A bit of Review Review, Dry Run, Program.
Computer Science II First With files.
Presentation transcript:

Review Dry Run A Little More Math Fix it Online time Intro to Programming Review Dry Run A Little More Math Fix it Online time

Learning Objectives Be able to Dry run a program that includes math operations and output Understand how to translate Math equations into Pascal. Be able to fix a program written poorly. Be able to develop a program in Pascal.

Which are valid variable names? Which are good variable names? Yo 3daysleft Summer time X Q Top Score Address Begin Writeln End X1 X^2 What? Number from 1 to 13 and write valid/invalid and good/bad.

Dry run 1 (What do you think the following program does?) {Mr. Smith's Sample Program} {Dry Run #2} {5-20-2015} program DryRunTest; uses crt; var a,b,c:integer; begin clrscr; a:= 20; b:= 16; c:= a+b; writeln(a, b, c); b:= c – 2*(a+b) -6; a:= c + b; end. Dry run 1 (What do you think the following program does?)

Math Math Pascal Code Example + Ans:= first+second; - Ans:= second – first; x * Ans := first * second; ÷ / Ans := first / second () Ans := (first + 2)/second; π PI Ans := PI; 52 sqr Ans := sqr(first); √ Sqrt() Ans:= sqrt(first);

You turn: What is the result of the following? Expression Answer Type 2+ 12 5*(8-15) 5 + 6*3 6 + 4/2 – 8 (6+4)/2 – 8 (6+4)/(2-8) Sqrt(9) Sqrt(4*4 + 9) Sqrt(sqr(3) + sqr(4))

Fix the following Fix5-20.pas in the assignments folder Open it in Pascal, save it to your documents then fix it. Fix the following prograhm Fix it 1 {Finding the average of two numbers) Number1, number 2, The average:integers. start writeln("Please enter two numbers) readline(17, 13) number1+number2/2 = average Show The average of 17 and 13 is average stop

Write a program for one of the following Extension: Look up If..then to check if the sides entered actually do make a triangle.