Session Objectives# 24 COULD code the solution for an algorithm

Slides:



Advertisements
Similar presentations
Chapter 15 Debugging. Copyright © The McGraw-Hill Companies, Inc. Permission required for reproduction or display Debugging with High Level Languages.
Advertisements

CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
PHYS 2020 Pseudocode. Real Programmers Program in Pencil!  You can save a lot of time if you approach programming in a methodical way.  1) Write a clear.
COMPUTER PROGRAMMING I Understand Problem Solving Tools to Design Programming Solutions.
Repetition Control Structures School of Business Eastern Illinois University © Abdou Illia, Spring 2003 (Week 9, Friday 3/07/2003)
PSEUDOCODE & FLOW CHART
LECTURE 1 CMSC 201. Overview Goal: Problem solving and algorithm development. Learn to program in Python. Algorithm - a set of unambiguous and ordered.
ITEC113 Algorithms and Programming Techniques
Chapter 2- Visual Basic Schneider
Program Flow Charting How to tackle the beginning stage a program design.
Program Flow Charting How to tackle the beginning stage a program design.
Algorithm Design CS105. Problem Solving Algorithm: set of unambiguous instructions to solve a problem – Breaking down a problem into a set of sub- problems.
Chapter 2: Algorithm Discovery and Design
Problem Solving Chapter 2. What is an algorithm? n A solution to a problem that is: –Precise –Effective –Terminating.
Chapter 3 Planning Your Solution
The Program Design Phases
Review Algorithm Analysis Problem Solving Space Complexity
PRE-PROGRAMMING PHASE
Programming Concepts and Languages Chapter 12 – Computers: Understanding Technology, 3 rd edition 1November
Fundamentals of C programming
ALGORITHMS AND FLOWCHARTS
Algorithms A Central Heating system Start Is temp <19
Flow Charting. Goals Create Algorithms using Flow Charting procedures. Distinguish between Flow Charting and Pseudocode. Top-Down Design Bottom-up Design.
Design the program Create a detailed description of program –Use charts or ordinary language (pseudocode) Identify algorithms needed –Algorithm: a step-by-step.
A Level Computing#BristolMet Session Objectives U2#S9 MUST identify operators and operands SHOULD describe different types of operator COULD Create an.
The Software Development Life Cycle. Software Development SDLC The Software Development Life-Cycle Sometimes called the program development lifecycle.
By the end of this session you should be able to...
Extended Prelude to Programming Concepts & Design, 3/e by Stewart Venit and Elizabeth Drake Chapter 2: Flowcharts.
© 2011 Pearson Addison-Wesley. All rights reserved. Addison Wesley is an imprint of Stewart Venit ~ Elizabeth Drake Developing a Program.
C++ Programming Language Lecture 2 Problem Analysis and Solution Representation By Ghada Al-Mashaqbeh The Hashemite University Computer Engineering Department.
Flowcharts.
Pseudocode. Simple Program Design, Fourth Edition Chapter 2 2 Objectives In this chapter you will be able to: Introduce common words, keywords, and meaningful.
Pseudocode Simple Program Design Third Edition A Step-by-Step Approach 2.
Review, Pseudocode, Flow Charting, and Storyboarding.
A Level Computing#BristolMet Session ObjectivesU2#S12 MUST describe the terms modal and pretty printing in term of input and output facilities. SHOULD.
Computer Programming I Summer 2011
CS 240 – Computer Programming I Lab Kalpa Gunaratna –
How Are Computers Programmed? CPS120: Introduction to Computer Science Lecture 5.
The Hashemite University Computer Engineering Department
The Department of Engineering Science The University of Auckland Welcome to ENGGEN 131 Engineering Computation and Software Development Lecture 2 Debugging,
A Level Computing#BristolMet Session Objectives#U2 S3 MUST use/read programme flow charts accurately SHOULD adapt the calculator programme to include a.
Chapter 2- Visual Basic Schneider1 Chapter 2 Problem Solving.
Introduction to Computers Lesson 13A. home Computer Program A set of instructions or statements, also called code, to be carried out by the computer’s.
GCSE Computing#BristolMet Session Objectives #23 MUST understand what is meant by the programming term iteration SHOULD describe methods of looping used.
Algorithms and Pseudocode
INTRODUCTION TO COMPUTER PROGRAMMING(IT-303) Basics.
Algorithms and Flowcharts
CHAPTER 2 GC101 Program’s algorithm 1. COMMUNICATING WITH A COMPUTER  Programming languages bridge the gap between human thought processes and computer.
Learning outcomes 5 Developing Code – Using Flowcharts
ALGORITHMS AND FLOWCHARTS
Understand Problem Solving Tools to Design Programming Solutions
Do it now activity Last lesson we used Flowol to create a solution to a problem a computer could solve. Identify what each symbol does:
Chapter 2- Visual Basic Schneider
Think What will be the output?
Understand Problem Solving Tools to Design Programming Solutions
Algorithms An algorithm is a sequence of steps written in the form of English phrases that specific the tasks that are performed while solving the problem.It.
ALGORITHMS AND FLOWCHARTS
Algorithms and Flow Charts
For -G7 programing language Teacher / Shamsa Hassan Alhassouni.
ALGORITHMS AND FLOWCHARTS
Chapter 2- Visual Basic Schneider
CSC128 FUNDAMENTALS OF COMPUTER PROBLEM SOLVING
Chapter 2- Visual Basic Schneider
Data and Flowcharts Session
Data and Flowcharts Session
Flowcharts and Pseudo Code
Introduction to Programming
Data and Flowcharts Session
WRITING AN ALGORITHM, PSEUDOCODE, AND FLOWCHART LESSON 2.
Presentation transcript:

Session Objectives# 24 COULD code the solution for an algorithm SHOULD write pseudocode for an algorithm MUST identify flow chart symbols Recreate the solution in a high level language with a continue or exit clause.

Pseudocode Flow Chart Syntax Error Logic Error Algorithm IDE Key Words Key Words Pseudocode Flow Chart Syntax Error Logic Error Algorithm IDE

Flow Chart Symbols Revisited Using white boards display what these symbols mean? 1. 2. 3. 4. 5. START/STOP Decision (IF or CASE Statements) Process either arithmetic ‘a + b’ or action ‘open file’ Input or Output Subroutine symbol – a subroutine is like a program within the program. It is used to simplify complex flow charts

Flow Charts KEY POINTS Commands are in caps, variables in lower case e.g Processes are generally a LET statement Other constructs include: IF process ELSE process 2 ENDIF or Loops (FOR –NEXT, REPEAT – UNTIL or WHILE – END WHILE) Pseudocode START/BEGIN INPUT width INPUT height LET area = width * height OUTPUT area STOP/END What will this programme do? Now write an algorithm for this programme START Input Width Input Height Area = Width x Height Output Area STOP

Creating Flow Charts & Pseudocode Flow charts and pseudocode are methods of designing algorithms to solve problems. They are useful to make sure the logic of the algorithm is correct with no logic errors before starting to programme, when the programmer is then faced with the prospect of language specific syntax errors. Logic errors – problems with the flow and structure of a programme Syntax errors – problems with the spelling and punctuation of a programme. TASKS: Now turn to page 156 and complete tasks 1 – 4. Extension Task 1 and the code a solution to any of your algorithms in Python. Aim to include a continue/exit feature.