New Mexico Computer Science For All More Algorithms Maureen Psaila-Dombrowski.

Slides:



Advertisements
Similar presentations
Welcome Back to School!!! Mr. Sortina.
Advertisements

1 ICS102: Introduction To Computing King Fahd University of Petroleum & Minerals College of Computer Science & Engineering Information & Computer Science.
New Mexico Computer Science For All Decomposition in Computer Programming Maureen Psaila-Dombrowski.
New Mexico Computer Science For All
CompSci Recursion & Minimax Playing Against the Computer Recursion & the Minimax Algorithm Key to Acing Computer Science If you understand everything,
Solve Systems of Linear Equations with a Common Term Using the Elimination Method.
New Mexico Computer Science For All Introduction to Algorithms Maureen Psaila-Dombrowski.
Computer Programming Basics. Computer programs are a detailed set of instructions given to the computer They tell the computer: 1. What actions you want.
10-1 Programming Remember: –programming language –how to program (conceptually) –intro to programming the “ROBOT” computer In this lecture: –programming.
Computational Fluency Flexible & Accessible Strategies for Multi-digit Addition and Subtraction Math AllianceMarch 30, 2010 Beth Schefelker and DeAnn Huinker.
Problem Solving Through Coding Names. PROBLEM SOLVING PROCESS UNDERSTAND THE PROBLEM: READ OR LISTEN TO THE PROBLEM. MAKE A PLAN TO SOVLE THE PROBLEM-
Solving a System of Equations using Multiplication
Scientific Notation Recognize and use scientific notation.
Objective How to solve Integer problems
Make every minute count!. If you answered yes to any of these then you need some help with time management Have you ever: -forgotten homework? -handed.
Place Value & Rounding Review. Place Value For the number 2, : The 2 is in the ___ place. The 6 is in the ___ place. The 4 is in the ___ place.
Computer Lab “Teach-To’s” Classroom Expectations
Recursion Opening Discussion zWhat did we talk about last class? zDo you have any questions about the assignment? zWhat is a recursive function?
CS 1308 Computer Literacy and The Internet Software.
Click mouse. EQUATIONS The important thing to remember about equations is that both sides must balance (both sides must equal each other). This means.
New Mexico Computer Science For All Sorting Algorithms Maureen Psaila-Dombrowski.
Lecture 13: 10/10/2002CS149D Fall CS149D Elements of Computer Science Ayman Abdel-Hamid Department of Computer Science Old Dominion University Lecture.
Problem Solving Heuristics ABLE Teacher Academy. Polya Check your solution. Substitute your answer or results back into the problem. Are all of the conditions.
EMSA Testing Strategies Foldable.  It’s Easy! Just remember  CUBES How can I do well on the test??
New Mexico Computer Science For All Search Algorithms Maureen Psaila-Dombrowski.
3434 Fractions By Mr. Walker. What is a Fraction? A fraction is just a smaller part of something else. If you have one piece of the pizza, you are only.
Algorithms and Pseudocode
CompSci Recursion & Minimax Recursion & the Minimax Algorithm Key to Acing Computer Science If you understand everything, ace your computer science.
Chapter Revision Decimals The chapter Is about decimals, you learn about place value with decimals, how to estimate with decimal equation, how.
Algorithms and Flowcharts
Lists and Sorting Algorithms
Leadership Team October 29, Clear Learning Goals Sort evidence from observation and determine performance level Demonstrate effective coaching strategies.
Algorithms and Pseudocode CS Principles Lesson Developed for CS4 Alabama Project Jim Morse.
LOGICFUSION’S HANDS-ON ROBOTICS EV3 LEVEL 2! Welcome to.
Integer Addition and Subtraction. Integer Addition Rules Rule #1 – If the signs are the same, pretend the signs aren’t there. Add the numbers and then.
FLOWCHARTS Part 1.
“SPEEDBOAT” THE RETRO SPACE
Completing the Square 8
IGCSE 6 Cambridge Effectiveness of algorithms Computer Science
Introduction to Programmng in Python
Looping and Random Numbers
Solving Mazes Troy Mahon.
Place Value and Rounding
Computer programming III. Algorithms.
Design and Technology Academic Year 2017/2018 Grade 7 First Semester.
Binary Search Back in the days when phone numbers weren’t stored in cell phones, you might have actually had to look them up in a phonebook. How did you.
Scientific Notation.
exa.im/stempy16.files - Session 12 Python Camp
Sequencing Learning Objective: to be able to design algorithms that use sequencing.
EXPLORING COMPUTER SCIENCE Journal Entries, Portfolio Entries, And Check Your Understanding Unit 2 – Strand 2 Problem Solving This unit focuses on.
·Like a rectangle but slanted ·Can't use slanted lines for area
Recognize and use scientific notation.
For example:
Computational Thinking for KS3
Problem Solving and Algorithm Design
adapted from Recursive Backtracking by Mike Scott, UT Austin
Recognize and use scientific notation.
Scientific Notation.
March 4, Math 201 OBJECTIVE: Students will be able to solve and explain two-step equations involving whole numbers. AIM: How do we use inverse.
Recognize and use scientific notation.
Your Name: Blockly Games: MAZE.
Unit 1: Principles of Computer Science
Computational Thinking
A short-hand way of writing large numbers without
Recognize and use scientific notation.
Ms. Hines’ Classroom Website
Classroom Rules and Policies
Mod 3 Lesson 2 Me First! Sorting
Algorithms to Solve Mazes An Application of Graph Theory
Introduction to Computer Science
Presentation transcript:

New Mexico Computer Science For All More Algorithms Maureen Psaila-Dombrowski

Algorithms Algorithm: A set of instructions that can be used repeatedly to solve a problem or complete a task. ▫As you problem grows, the need for a good algorithm grows  Need a systematic way to solve the problem Two Problems ▫Counting ▫Mazes

Counting Something we all know about Three counting problems ▫Students in your class ▫Students in your school ▫High school students in your state

Count Students in Class Easy ▫Teacher can count ▫Students can count off Pseudocode set ClassCount to 0 while (students left in class to count) set ClassCount to ClassCount + 1

Count Students in School Harder ▫One possible method – “Brute Force”  Gather the students  Line them up  Count them ▫Have someone count the ▫Have them count off ▫Another method – Divide and Conquer (algorithmic principle, break the problem into smaller pieces and then solve)  Leave students in classrooms  Have each classroom count their students (ClassCount)  Add up the students from classroom (SchoolCount)

Pseudocode: Count Students in School In each classroom set ClassCount to 0 while (students left in class to count) set ClassCount to ClassCount + 1 For the school set SchoolCount to 0 while (still classrooms left to count) go to each classroom ask number of student in class (ClassCount) set SchoolCount = SchoolCount + ClassCount

High School Students in State Even Harder ▫Can’t line them up ▫Divide and Conquer  Have each School count their students ▫At each school ▫Leave students in classrooms ▫Have each classroom count their students ▫Add up the students from each classroom (ClassCount)  Have the schools report their student numbers (SchoolCount)  Add up all the School’s student numbers to get the number of high school students in the state (StateCount)

Pseudocode: Count Students in State In each classroom in each school set ClassCount to 0 while (students left in class to count) set ClassCount to ClassCount + 1 For the school set SchoolCount to 0 while (still classrooms left to count) go to each classroom ask number of student in class (ClassCount) set SchoolCount = SchoolCount + ClassCount For the state set StateCount to 0 while (still schools left to count) go to each school ask number of student in school (SchoolCount) set StateCount = StateCount + SchoolCount

Mazes Easy - Don’t need an algorithm

Mazes Perhaps you need an algorithm (systematic approach) for this one

Mazes – Two Approaches Wall Following ▫Good if you can’t see the whole maze ▫Works on simply connected mazes ▫Pick a wall (right or left) and keep following it – never change

Mazes – Two Approaches Wall Following Pseudocode (left wall following) Find the nearest wall on the left Turn left if you can and move forward If you can’t turn left Move forward if you can If you can’t move forward Turn right and move forward

Left Wall Following Video Reference: ‪ AloucasHellas. (2013, October 10). Maze Solving Algorithms: Left Hand Rule (LHR) [Video file]. Retrieved from s

Mazes – Two Approaches Dead End Filling ▫Good if you CAN see the whole maze ▫Find all the dead ends and fill them in ▫Works if there are dead ends Find All the Dead Ends Fill Them InMaze

Mazes – Two Approaches Dead End Filling Pseudocode: Find dead ends Scan the maze Identify dead end (walls on 3 sides) Remember the dead ends Fill in the dead ends Go to dead end While not at junction (walls on 2 sides) Fill in maze Solution is left – solve maze!

Dead End Filling Video Reference: ‪ Mazemaster225. (2013, October 10). Maze Strategy: Dead End Filling. [Video file]. Retrieved from I

Summary Algorithm: A set of instructions that can be used repeatedly to solve a problem or complete a task. ▫The bigger the problem the more you need a systematic way to solve the problem Two Problems ▫Counting  Divide and Conquer: Algorithmic principle ▫Mazes  Wall Following  Dead End Filling