Initial Steps in Program Development [Using problem defined in Ch. 1 of Stern & Stern]

Slides:



Advertisements
Similar presentations
Chapter 3: Modularization
Advertisements

Chapter 2: Modularization
Repetition Control Structures School of Business Eastern Illinois University © Abdou Illia, Spring 2003 (Week 9, Friday 3/07/2003)
Computer Programming Rattapoom Waranusast Department of Electrical and Computer Engineering Faculty of Engineering, Naresuan University.
Introductory Remarks. COURSE OBJECTIVES: (TAKEN FROM PREFACE) 1. To teach students how to design programs so that they are easy to read, debug, adapt,
Mark Dixon Page 1 07 – Reports. Mark Dixon Page 2 Session Aims & Objectives Aims –To use reports to produce more readable documents Objectives, by end.
Modules, Hierarchy Charts, and Documentation
Pseudocode.
COBOL for the 21 st Century Stern, Stern, Ley Chapter 1 INTRODUCTION TO STRUCTURED PROGRAM DESIGN IN COBOL.
Pseudocode.
PAYROLL AND MODERN MAIL HANDLING METHODS Topic 21 Organisations:
1 Algorithm…. 2 Algorithm: Is a planned set of steps to solve certain problem Ex.: Assume for instance that the gross pay of an employee is to be calculated.
COBOL for the 21st Century
Computer Programming 12 Lesson 2 - Organizing the Problem By Dan Lunney.
DCT 1123 Problem Solving & Algorithms
Sw development1 Software Development 1.Define the problem (Analysis) 2.Plan the solution 3.Code 4.Test and debug 5.Maintain and Document.
Structured COBOL Programming, Stern & Stern, 9th edition
Getting Started Chapter 2 Presentation © Copyright 2002, Bryan Meyers
Chapter To familiarize you with  Why COBOL is a popular business-oriented language.  Programming practices and techniques  History of COBOL.
1-1 COBOL for the 21 st Century Nancy Stern Hofstra University Robert A. Stern Nassau Community College James P. Ley University of Wisconsin-Stout (Emeritus)
Planning for the Solution
Chapter 2: Beginning the Problem-Solving Process
Pseudocode Demo for Payroll.c
Instructor Information: Dr. Radwa El Shawi Room: Week # 1: Overview & Review.
Lesson 3 McManus COP  You have to tell them ◦ what to do ◦ what to use ◦ in what order to do itand ◦ what to do if your user does not do what.
DATA STRUCTURES (CS212D) Week # 1: Overview & Review.
1 Interactive vs Batch Programs Cobol suited for developing both types of programs Interactive programs Accept input data from keyboard Input data processed.
CS CS Computing for Business Instructor:David Tucker GTA:Batul Mirza.
Printing on power systems Program/ Command Data Report Layout (Printer File) Job Output Queue *FILE Spooled File.
Property of Jack Wilson, Cerritos College1 CIS Computer Programming Logic Programming Concepts Overview prepared by Jack Wilson Cerritos College.
Coding Design Tools Rachel Gauci. What are Coding Design Tools? IPO charts (Input Process Output) Input- Make a list of what data is required (this generally.
CPSC3111/CISM3111 COBOL Structured COBOL Programming Text: murach’s structured COBOL Authors: Murach, Prince, Menendez.
SYSTEMSDESIGNANALYSIS 1 Chapter 20 Software Engineering Jerry Post Copyright © 1997.
Chapter 2 Pseudocode. Objectives To introduce common words, keywords and meaningful names when writing pseudocode To define the three basic control structures.
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.
GOALS BUSINESS MATH© Thomson/South-WesternLesson 1.1Slide 1 1.1Hourly Pay and Salary Calculate gross pay for hourly-rate employees Calculate gross pay.
Cosc175 - Define Problem/Design Solution/Pseudocode/Trace 1 DEFINE THE PROBLEM.
Any Questions!. Test Coming Up! Agenda Printing with Externally Described Printer Files Arrays.
1 Chapter 5 – The Procedure Division File handling statements –OPEN statement Initiates processing for a file Input Output Each file opened must have been.
 Structure charts (last lesson)  Screen and page layout diagrams provide  A sketch of each page (screen) of the program  A list of the content, including.
ICS124 Session 8 Structured Programming 1. By the end of this section the student will be able to:  List the steps of a model Systems Development Life.
5.3 Sorting Techniques. Sorting Techniques Sorting is the process of putting the data in alphabetical or numerical order using a key field primary key.
Any Questions? Week 1 - 2nd Lecture Intro to COBOL Programming Defining Files and Processing Data.
Microsoft Access 2000 Creating Queries, Reports and Web Pages.
CPSC 203 Introduction to Computers T43, T46 & T68 By Jie (Jeff) Gao.
Flowcharts. Learning Objectives To learn how to break down tasks How to create a flowchart.
Any Questions! 2 Agenda Moving data Arithmetic Verbs Compute statement.
HNC Flow Chart 1 IT Systems Analysis and Design SSADM – Design.
Copyright © 2007 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 8: Streams and Files Problem Solving, Abstraction, and Design using.
371 Structured COBOL Programming Nancy Stern Hofstra University Robert A. Stern Nassau Community College James P. Ley University of Wisconsin-Stout John.
Chapter 2: Input, Processing, and Output Starting Out with Programming Logic & Design by Tony Gaddis (with instructor modifications) 1-1.
Adding Reports to a Database. Why do we use Reports? Reports are well-designed printed pages that offer several advantages: Reports are well-designed.
CS 101 – Oct. 7 Solving simple problems: create algorithm Structure of solution –Sequence of steps (1,2,3….) –Sometimes we need to make a choice –Sometimes.
Array Applications. Objectives Design an algorithm to load values into a table. Design an algorithm that searches a table using a sequential search. Design.
Functions Commands Programming Steps Examples Printing Homework Hints.
WELME TO. Time Card Calculator If any company has deficiency of time and he cannot manage his time properly, then the sitiata has a solution. Sitiata.
An Introduction to Programming with C++1 Beginning the Problem- Solving Process Tutorial 2.
I Input (data) P Process (calculations to be done on input) O Output (information) IPO Charts.
QRB 501 Week 2 Learning Team Case Studies To purchase this material click on the link NEW/QRB-501-Week-2-Learning-Team-Case-
QRB 501 Week 5 Learning Team Case Studies Complete the following case studies from Ch. 21 of Business Math: Case Study 21-1, p. 768 Case Study 21-2, p.
IT 210 Week 2 Individual Application-Level Requirements To purchase this material link
IT 210 Week 7 Chapter 5 Programming Problems To purchase this material link Programming-Problems.
Algorithm & Flowchart.
Databases.
CHAPTER 2 & 3: Pseudocode and Developing and Algorithm
Pseudocode.
Pseudocode algorithms using sequence, selection and repetition
Structured Program Design
An Introduction to Structured Program Design in COBOL
Presentation transcript:

Initial Steps in Program Development [Using problem defined in Ch. 1 of Stern & Stern]

Define the Problem word problem (pg 16 in Stern & Stern): A software developer in a large company is assigned the task of calculating and printing weekly wages or gross pay for all non-salaried personnel. look for key nouns and verbs: A software developer in a large company is assigned the task of calculating and printing weekly wages or gross pay for all non-salaried personnel.

IPO chart for key elements InputProcessOutput Non-salaried employee record - Calculate weekly wages - Print weekly wages (weekly wage report)

Expand IPO chart (add detail as you go) InputProcessOutput (employee record:) Emp-name Emp-hours Emp-rate - Calculate wages = emp-hours * emp-rate - Print wages: put emp-name, emp-hours, emp-rate, wages on output line (weekly wage report:) Standard format report Name-out Hours-out Rate-out Wages-out

Determine record layout (input) Input Record Layout (employee-record) Field nameSizeData typedecimals? Employee-name-in Hours-worked-in Hourly-rate-in alphanumeric numeric

Determine record layout (output) Output Record Layout (print-rec) Field nameSizeData typedecimals? Name-out Hours-out Rate-out Weekly-wages-out alphanumeric numeric (formatted) Note: Filler spaces and titles have been ignored. Use a printer spacing chart next.

Expand into an algorithm …either pseudocode… Start Open files for input and output Dowhile there are records Read an employee-record (at end of file, set a flag) Not at end [Process employee record for wages] clear the output record move input fields to output fields calculate wages = hours-worked * hourly-rate move wages to output field write out record [ ] End-read End-do Close input and output files Stop

...or a flowchart (see P0-structure.hierarchy.doc link from web page)