0% found this document useful (0 votes)
5 views29 pages

Programming Basics and Flowcharting Guide

This document provides an introduction to programming and flowcharting, covering key concepts such as programming languages, types of errors, and control structures. It outlines the software development lifecycle (SDLC) phases and methodologies, as well as flowchart symbols used to represent processes. Additionally, it discusses the role of Integrated Development Environments (IDEs) in automating software development tasks.

Uploaded by

romeothird15
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
5 views29 pages

Programming Basics and Flowcharting Guide

This document provides an introduction to programming and flowcharting, covering key concepts such as programming languages, types of errors, and control structures. It outlines the software development lifecycle (SDLC) phases and methodologies, as well as flowchart symbols used to represent processes. Additionally, it discusses the role of Integrated Development Environments (IDEs) in automating software development tasks.

Uploaded by

romeothird15
Copyright
© All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd

Introduction to

Module 1 Programming
CC S 1 4 0 0
and
Flowcharting
Objectives

Familiarize with
Define
programming
programming
universals

Identify
Create a
flowchart
flowchart
symbols

2
The Task of
Programming

3
❑ Programming
− the process of preparing an instructional program for a device
(such as a computer)
• program – set of instructions that helps the computer to perform
tasks

❑ Learning a computer programming language requires


learning both its vocabulary and syntax
− syntax – rules of any language

❑ Types of Errors
− Syntax errors
− Run-time errors
− Logical errors

4
Programming Universals

5
❑ Programming language
− used to write a program or set of instructions
− primary classifications
• Machine level language
• Assembly level language
• High-level language

6
❑ Machine language
− low-level of programming language
− handles binary data
− directly interacts with system
− not portable and non-readable to humans

7
❑ Assembly language
− a low-level language
− consists of a set of instructions in a specific format called
commands
− uses symbols to represent field of instructions
− very close to machine level language
− should have an assembler to translate assembly level program
to machine level program
− in human-readable format and takes lesser time to write a
program and debug it
Assembly Language Machine Code

SUB AX, BX 0010101110000011

MOV CX, AX 100010111001000


MOV DX, 0 10111010000000000000000
8
❑ High-level language
− uses format or language that is most familiar to users
− instructions in this language are called codes or scripts
− needs a compiler and interpreter to convert high-level
language program to machine level language
− examples: C++, Python, Java
− easy to write and is less time-consuming
− human-readable language

if age < 18 {
printf("You are not eligible to vote");
} else {
printf("You are eligible to vote");
}

9
❑ Interpreter
− program that translates programming language instructions
one line at a time

❑ Compiler
− translates entire program at one time

❑ Run a program by issuing a command to execute the


program statements

❑ Test a program by using sample data to determine


whether the program results are correct

10
❑ Control structures
− logic components in programs
− Sequence structure
• steps execute one after another, without interruption
− Selection structure
• used to perform different tasks based on a condition
− Loop structure
• repeats actions while some condition remains unchanged

11
Procedural
Programming

12
❑ Procedural programs
− consist of a series of steps or procedures that take place one after
the other
− based on the concept of calling procedure
• procedures - or routines, subroutines or functions, consist of a series
of computational steps to be carried out
− examples:
• COBOL
• BASIC
• ALGOL
• FORTRAN
• Pascal
• C

❑ During a program execution, any given procedure can be called


by other procedures or by itself.

13
14
Software
Development
Methodology

15
❑ Software development
− process of creating, testing, and maintaining software
products and services that meet users needs

❑ Software development methodologies


− frameworks or models that guide the software development
process, including the activities and deliverables
− also defines the roles and responsibilities of the development
team

16
Phases of SDLC
1. Project planning
2. Gathering requirements and analysis
3. Design
4. Coding or implementation
5. Testing
6. Deployment
7. Maintenance

17
Some SDLC Models
❑ Waterfall
❑ Agile
❑ Spiral

18
F LO W C H A RT –

Flowchart Symbols
GRAPHICAL
R E P R E S E N TAT I O N
OF THE STEPS IN
A PROCESS

19
Symbol Name Function

• Used at the beginning and end of the algorithm


Start/End to show start and end of the program

Arrows • Shows relationships between different shapes


• Used for denoting program inputs and outputs
Input/Output

• Indicates processes like mathematical operations


Process

• Stands for decision statements in a program,


where answer is usually Yes or No
Decision • A decision or branching point
• Lines representing different decisions emerge
from different points of the diamond
• Connects two or more parts of a flowchart, which
are on the same page
On-page • Indicates that the flow continues where a
Connector matching symbol (containing the same letter) has
been placed

Off-page • Connects two parts of a flowchart which are


Connector spread over different pages

20
❑ A program that prints the sum
of the two integers entered by
the user.

21
22
Flowchart Sequence,
Selection, and Looping
Three Basic Programming Constructs

23
Sequence

24
Selection

Yes

No

25
Looping

Yes

No

26
Integrated
Development
Environment

27
IDE
− Integrated Development Environment
− a coding tool that aids in automating the editing, compiling,
testing, and other steps of an SDLC while making it simple for
developers to execute, write, and debug code
− specifically made for software development and includes a
number of tools that are used in the creation and testing of
the software

28
These are
some
Python
IDEs

29

You might also like