[go: up one dir, main page]

0% found this document useful (0 votes)
3 views23 pages

Module 1F CE Computer Fundamentals Programming 6 28

The document provides an introduction to computer programming, explaining what a program is, the role of programmers, and the distinction between software and hardware. It outlines different types of programming languages, including low-level and high-level languages, and describes the functions of compilers and interpreters. Additionally, it discusses the evolution of programming languages through various generations, from machine language to languages used in artificial intelligence.

Uploaded by

ivanandrade.com1
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)
3 views23 pages

Module 1F CE Computer Fundamentals Programming 6 28

The document provides an introduction to computer programming, explaining what a program is, the role of programmers, and the distinction between software and hardware. It outlines different types of programming languages, including low-level and high-level languages, and describes the functions of compilers and interpreters. Additionally, it discusses the evolution of programming languages through various generations, from machine language to languages used in artificial intelligence.

Uploaded by

ivanandrade.com1
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
You are on page 1/ 23

6

Module 1: Introduction to
Computer Programming
What is a Program?
7

• An organized list of instructions that, when executed, causes


the computer to behave in a predetermined manner.

• A computer program, or just a program, is a sequence of


instructions, written to perform a specified task on a
computer.

• A program is like a recipe. It contains a list of ingredients


(called variables) and a list of directions (called statements)
that tell the computer what to do with the variables. The
variables can represent numeric data, text, or graphical
images.

• Without programs, computers are useless!


What is a Program?
8

• an app, application, software application or


software program is the most common software on
the computer that performs a special function or
task.
• For example, Microsoft Word is a word processor
program that allows users to create and write
documents and the browser you are using to view
this page is a program.

• Without programs, a computer would still work with


the operating system, but you would not be able to
do anything.
What is Programming?
9

It is an act of making programs


Without programs, computers are useless!

Programmer. A programmer, developer, dev, coder,


or software engineer is a person who creates
computer software. The term computer programmer
can refer to a specialist in one area of computers or
to a generalist who writes code for many kinds of
software.
What is software?
10

• Generic
• General
• does not necessarily always mean "program" or
"application" (e.g. a software "library" or "framework" is
not a "program" or "application", but are used to
facilitate the functional requirements of "programs" or
"applications").
Without programs, computers are useless!
Computer software, or simply
software, is a collection of data
or computer instructions that tell
the computer how to work. This
is in contrast to physical
hardware, from which the system
is built and actually performs the
work. Wikipedia
Why do programmers make computer
programs?
11

• To simplify task

• Provide accurate results

• Aide in facilitating day-to-day activities


a computers are useless!
LLL vs HLL
12

Low Level Language (LLL) – language that can convert


to machine code without a compiler or interpreter, and
the resulting code runs directly on the CPU/Processor.
(also known as the machine language or assembly
language – the zeros and ones (0,1))

High Level Language (HLL) – needs a compiler or


interpreter to convert the instruction into language that
could be understood by CPU/Processor.

a computers are useless!


What is CPU or Processor?
13

• CPU means central processing unit

• “Brain” of the computer

• Executes commands or instructions

Central processing unit


A central processing unit a computers
(CPU) is the are useless!
electronic circuitry within a computer that
carries out the instructions of a computer
program by performing the basic arithmetic,
logic, controlling, and input/output (I/O)
operations specified by the instructions.
Compiler
14

• It is a program that converts high level language to


low level language that could be understood by
the CPU (this process is called “Compiling”)

• Commonly compiles instruction known as the


“Code”
Interpreter
15

• It is a program that interprets (without


undergoing the process of compiling) high level
language to low level language that could be
understood by the CPU.

• Commonly compiles instruction known as the


“Script”
Types of Programming Language
16

• Web languages
• Software languages
• The different generations of languages
• Procedure oriented programming
• Object oriented programming
Types of Programming Language
17

Web Languages
• HTML
• XML
• JAVASCRIPT
• VBSCRIPT
• PHP
• ASP
• JAVA
Types of Programming Language
18

Software Languages
• C
• C++
• Visual Basic
• JAVA
• C#
Types of Programming Language
19

The different generations of languages


• 1st Generation Language (1GL)
• 2nd Generation Language (2GL)
• 3rd Generation Language (3GL)
• 4th Generation Language (4GL)
• 5th generation language (5GL)
The different generations of languages
20

First generation languages (abbreviated as 1GL)

Represent the very early, primitive computer


languages that consisted entirely of 1's and 0's -
the actual language that the computer
understands (machine language).
The different generations of languages
21

Second generation languages (2GL)

• Represent a step up from the first generation


languages. Allow for the use of symbolic
names instead of just numbers.
• Second generation languages are known as
assembly languages.
• Code written in an assembly language is
converted into machine language (1GL).
The different generations of languages
22

Third generation languages (3GL)

• With the languages introduced by the third


generation of computer programming, words
and commands (instead of just symbols and
numbers) were being used.
• These languages therefore, had syntax that
was much easier to understand.
• Third generation languages are known as
"high level languages" and include C, C++,
Java, and Javascript, among others
The different generations of languages
23

Fourth generation languages (4GL)


• The syntax used in 4GL is very close to
human language, an improvement from the
previous generation of languages.

• 4GL languages are typically used to access


databases and include SQL and ColdFusion,
among others.
The different generations of languages
24

Fifth generation languages (5GL)


• Fifth generation languages are currently
being used for Neural Networks.

• A Neural Network is a form of Artificial


Intelligence that attempts to imitate how the
human mind works.
Example Code of Visual Basic
25
Example Code of Python
26
Example Code of C#
27
28

End of Module 1
Note: prepare for a quiz next meeting

You might also like