The Software Construction Process

Slides:



Advertisements
Similar presentations
Etter/Ingber Engineering Problem Solving with C Fundamental Concepts Chapter 1 Engineering Problem Solving.
Advertisements

Senem Kumova Metin Introduction to Programming CS 115 Introduction to Computing PART I : Computer Basics PART II: Introduction to Computing/Programming.
Engineering Problem Solving With C++ An Object Based Approach Fundamental Concepts Chapter 1 Engineering Problem Solving.
1 Engineering Problem Solving With C++ An Object Based Approach Fundamental Concepts Chapter 1 Engineering Problem Solving.
Computer Hardware.
C++ Programming: From Problem Analysis to Program Design, Third Edition Chapter 1: An Overview of Computers and Programming Languages C++ Programming:
CS 101 Problem Solving and Structured Programming in C Sami Rollins Spring 2003.
Starting Out with C++: Early Objects 5/e © 2006 Pearson Education. All Rights Reserved Starting Out with C++: Early Objects 5 th Edition Chapter 1 Introduction.
CS 0008 Day 2 1. Today Hardware and Software How computers store data How a program works Operators, types, input Print function Running the debugger.
CS102 Introduction to Computer Programming
Alternate Version of STARTING OUT WITH C++ 4 th Edition Chapter 1 Introduction to Computers and Programming.
Chapter Introduction to Computers and Programming 1.
CSC 125 Introduction to C++ Programming Chapter 1 Introduction to Computers and Programming.
Chapter 1 Engineering Problem Solving 1. Hardware and Software 2 A computer is a machine designed to perform operations specified with a set of instructions.
CISC105 General Computer Science Class 1 – 6/5/2006.
Chapter 1 Introduction to Computers In this chapter we describe the major components of a computer system and explain how information is represented in.
UniMAP Sem1-08/09EKT120: Computer Programming1 Week 1 – Lecture 1.
Introduction to Computer Systems and the Java Programming Language.
CIS-165 C++ Programming I CIS-165 C++ Programming I Bergen Community College Prof. Faisal Aljamal.
C++ Programming: From Problem Analysis to Program Design, Third Edition Chapter 1: An Overview of Computers and Programming Languages.
CHAPTER 1 INTRODUCTION 1 st Semester H King Saud University College Of Applied Studies and Community Services CSC 1101 Computer Programming-1.
The Software Construction Process. Computer System Components Central Processing Unit (Microprocessor)
CHAPTER 1 INTRODUCTION 2 nd Semester H King Saud University College Of Applied Studies and Community Services CSC 1101 Computer Programming-1.
The Software Construction Process. Computer System Components Central Processing Unit (Microprocessor)
Computing Systems & Programming ECE Fundamental Concepts Chapter 1 Engineering Problem Solving.
Chapter 1 Computers, Compilers, & Unix. Overview u Computer hardware u Unix u Computer Languages u Compilers.
Copyright 2003 Scott/Jones Publishing Standard Version of Starting Out with C++, 4th Edition Chapter 1 Introduction to Computers and Programming.
A.Abhari CPS1251 Topic 1: Introduction to Computers Computer Hardware Computer components Connecting Computers Computer Software Operating System (OS)
UniMAP Sem2-10/11 DKT121: Fundamental of Computer Programming1 Introduction to C – Part 1.
Chapter 1 Introduction to Computers, the Internet and the Web.
Brief Version of Starting Out with C++ Chapter 1 Introduction to Computers and Programming.
C++ Programming: From Problem Analysis to Program Design, Fifth Edition Chapter 1: An Overview of Computers and Programming Languages.
Copyright © 2010 Pearson Education, Inc. Publishing as Pearson Addison-Wesley Chapter 1: Introduction to Computers and Programming.
By Kundang K Juman Hardware & Software. COMP102 Prog. Fundamentals I: Software / Slide 2 l Four components of a computer system: n CPU - central processing.
Introduction to Programming By: Prof. Muhammad Abu Baker Siddique 2 nd Lecture 1.
WHAT IS COMPUTER ? . A computer is a complex system consisting of both hardware and software components.
Inside a Computer. Computer Hardware/Software What is the difference? Computer Hardware.
Identify internal hardware devices (e. g
Chapter 1: Introduction to Computers and Programming
Chapter 1 Introduction 2nd Semester H
BASIC PROGRAMMING C SCP1103 (02)
Chapter 1: An Overview of Computers and Programming Languages
Engineering Problem Solving With C An Object Based Approach
CSC201: Computer Programming
Chapter 1: An Overview of Computers and Programming Languages
BASIC PROGRAMMING C SCP1103 (02)
Week 1 – Session 1 Pn. Yasmin Yacob 04 – KUKUM Sem2-06/07
Java programming lecture one
Chapter 1: An Overview of Computers and Programming Languages
Basic Computer Components
C++ Programming: From Problem Analysis to Program Design
BASIC OF THE COMPUTER SYSTEM. INPUT/OUTPUT INPUT DEVICES MOUSE KEYBOARD SCANNER OUTPUT DEVICES PRINTER MONITER.
Computer Parts There are many parts that work together to make a computer work.
Chapter 1: Introduction to Computers and Programming
Chapter 1: Computer Systems
Computer Science I CSC 135.
פרטים נוספים בסילבוס של הקורס
0. What is a Computer?.
Computer Electronic device Accepts data - input
Hardware & Software Programming. COMP102 Prog. Fundamentals I: Software / Slide 2 l Four components of a computer system: n CPU - central processing unit.
King Saud University College Of Applied Studies and Community Services CSC 1101 Computer Programming-1 Done By: Asmal Alosaimi Edited By: Fatimah Alakeel.
Computer Electronic device Accepts data - input
King Saud University College Of Applied Studies and Community Services CSC 1101 Computer Programming-1 Done By: Asmal Alosaimi Edited By: Fatimah Alakeel.
Introduction to Computer Programming
ITEC 1011 Introduction to Information Technologies 0. What is a Computer?
Data Communications and Computer Networks
An Overview of C.
Computer Electronic device Accepts data - input
ICS103 Programming in C 1: Overview of Computers And Programming
Chapter 1: Introduction to Computers and Programming
Presentation transcript:

The Software Construction Process

Computer System Components Internet Primary Storage (RAM) Network Interface Devices (Modem, Network Card) 01001101 10110101 11011001 10110100 00101011 01011001 10101010 01011011 10100110 01001011 Output Devices (Monitor, Printer) Input Devices (Mouse, Keyboard) Communications Bus Secondary Storage (Hard Drive, CD-ROM Drive) Central Processing Unit (Microprocessor)

A Software Requirement Develop a program that finds and prints all numbers between 1 and 10,000 that are divisible by both 7 and 3. For each number found, display the number and the product of the two quotients.

The Requirement and the Design Set number to 1 Develop a program that finds and prints all numbers between 1 and 10,000 that are divisible by both 7 and 3. For each number found, display the number and the product of the two quotients. No Number less than or equal to 10,000 Yes No Number divisible by 7 Yes No Number divisible by 3 Yes Print number information Increment number by 1 F

Boards, Tubes, and Patch Cables Application Program 01001101 10110101 11011001 10110100 00101011 01011001 10101010 01011011 10100110 01001011

Setting Switches Application Program 01001101 10110101 11011001 10110100 00101011 01011001 10101010 01011011 10100110 01001011

I/O Devices and Operating System 01010101 10101010 10101110 01001011 Operating System 01001101 10110101 11011001 10110100 00101011 01011001 10101010 01011011 10100110 01001011 Application Program

Assembly Language, Monitor, and Keyboard 01010101 10101010 10101110 01001011 Operating System 10111010 10101010 01011011 Assembler 01001101 10110101 11011001 10110100 00101011 01011001 LOOP: LOAD A, R1 LOAD 7, R2 TEST R1, R2 BRZ LOOP Application Program

Compiler (Syntax and Semantics) 01010101 10101010 Operating System 10111010 10101110 01001011 #include <stdio.h> int main (void) { int anAnswer; float aValue; anAnswer = aValue / 3; printf(“%d\n”,anAnswer); return 0; } Assembler 10101011 00101010 01101011 Compiler 11011001 10110100 00101011 01011001 Application Program

Algorithm in C Source Code aNumber = LOWNUMBER; while (aNumber <= HIGHNUMBER) { firstQuotient = aNumber / FIRSTDIVISOR; if ( (aNumber % FIRSTDIVISOR) == 0 ) { secondQuotient = aNumber / SECONDDIVISOR; if ( (aNumber % SECONDDIVISOR) == 0) { theProduct = firstQuotient * secondQuotient; printf("%d %7.2f %7.2f %8.2f\n",aNumber, firstQuotient, secondQuotient, theProduct); } // End if } // End if aNumber++; // Increment aNumber by one Note: This is only a portion of the complete C program

From Requirements to Running Program Design Fundamentals Software Requirements Design Method Coding Standards Software Design Text Editor C Header Files program.c (Source Code) Compiler (and Preprocessor) Function Libraries program.o (Object Code) Linker Input/Output Facilities program.exe (Executable Code) Operating System

Software Construction Process Requirements 1 DESIGN COMPILE 2 3 8 EDIT and SAVE 4 A BASELINE LINK E B D C 7 5 TEST and SQA RUN 6 Note: See next slide for meanings of A - E

Categories of Errors A: Compiler errors – doesn’t follow preprocessor or C syntax B: Linker errors – functions declared but not defined; no main function; function library not found C: Run-time errors – segmentation fault; out-of-range errors; wrong data types D: Logic errors – wrong use of control statements; errors in function arguments; algorithm coded incorrectly E: Design errors – doesn’t follow design or satisfy requirements; design has flaws 