Nothing Special   »   [go: up one dir, main page]

0% found this document useful (0 votes)
56 views11 pages

CP 2 Lesson 1

Download as docx, pdf, or txt
Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1/ 11

QUARTER 1

Introduction to Computer Programming 2

Reminder to Parents

Learners may need your guidance and assistance when it comes to some
lessons in this module. You may assist them in some process and directions in
answering question on their activities. Make sure that they will easily understand and
perform the skills needed to this module

Reminder to Learners

This module is created to assist you and make you understand in the easiest way
on how to understand Computer Programming 2. It is develop to guide you step by step
ways on how to create basic programming and how programming begins. This module
contains discussions, activities, practices and pre-test and quizzes for you to assess
your learning’s with regards this subject.

Introduction
In this subject, students are introduced to programming concepts. Students work
in a hands-on environment, allowing time to discuss and practice each programming
concept. Students learn to write and debug programs in an integrated development
environment. Topics include memory concepts, control structures, using built in
functions, building sub procedures and functions, error handling and sequential file
processing. This course also helps students gain basic HTML/JavaScript Programming
skills and is an entry point into both the Web and Windows app training paths .. This
course focuses on using HTML/JavaScript to implement programming logic, define and
use variables, perform looping and branching , develop user interfaces, capture and
validate user input, store data and create well-structured application. The focus will be
on coding activities that enhance the performance and scalability of the Web site
application.
Chapter 1 - Overview of Programming Languages

Learning Objective

1. Demonstrate an understanding of the history of programming languages


2. Explain the differences in the levels of programming languages.

Chapter 1 – Lesson 1- History of Programming Language

We all know that technology takes place in our world right now. Each and every
time on our day we use technology by means of using gadgets such as cellular phones,
computer desktop and laptops, tablets and even on our transportation we use
technology. But how does it start? Where did this what we called technology came
from? Now let me show who it all started.

What is Computer?

 It is an electronic device that manipulates information or data. It has the ability to


store, retrieve and process data.
 It is a programmable machine.
 It is a machine that can be instructed to carry out sequence of arithmetic or
logical operations automatically via computer programming.
 It is an electronic machine that is used for organizing, and finding words,
numbers and pictures, for doing calculation and for controlling other machines.
 It is a programmable electronic device designed to accept data, perform
prescribed mathematical and logical operations at high speed, and display the
results of these operations.

What is Program?

 It is a set of coded instructions that a computer can understand to solve a


problem or produce a desire result.
 It is a set of related measures or activities with a particular long-term aim.
 It a series of coded software instructions to control the operation of a computer or
other machine
 It is a sequence of instruction given to an electronic devices to perform in a pre-
determine way.
 It is written either in one of high-level programming language such as BASIC, C
or JAVA which are easier but execute relatively slowly, or in one low-level
language like assembly language or machine language which are very complex
but execute very fast.
 It is a collection of instructions that can be executed by a computer to perform a
specific task.
Two basic types of computer programs

1. Operating System
 It provides the most fundamental instructions a computer uses in its
operations.
 It is the software that supports a computer’s basic functions, such as
scheduling task, executing applications and controlling peripherals.
 It is the system software that manages computer hardware, software
resources and provides common services for computer program.

2. Application program

 It runs on the operating system and does specific jobs such as word
processing.
 It is a program or group of programs designed for end users.
 It may be bundle with the computer and its system software or published
separately.
 It may be coded as proprietary, open-source or university projects.

What is programming?

 It is the process and building an executable computer program to accomplish a


specific computing result or to perform a specific task.
 It involve task such as analysis, generating algorithms, profiling algorithm’s
accuracy and resource consumption and the implementation of algorithm in a
chosen programming language.
 It is a way to instruct the computer to perform various tasks or basically means
that you provided the computer a set of instructions that are written in a language
that the computer can understand.
 It is the art and science of creating or translating a set of ideas into a program. It
involves coding, modeling, simulating or presenting the solution to a problem by
presenting facts, data or information using pre-determined rules semantics on a
computer or any other device for automation.

What is programmer?

 A person who writes computer program


 Also called as software developer or a coder that creates computer software.

What is programming language?

 It is a formal language comprising a set of instructions that produce various kinds


of output.it is used in computer programming to implement algorithms.
 It is a set of commands, instructions and other syntax use to create a software
program.
 It is a vocabulary and set of grammatical rules for instructing a computer or
computing device to perform specific task.
 It has a unique set of keywords and a special syntax for organizing a program
instruction.

Two types of programming language

1. High Level Language


 These languages are designed to be easy to read and understand. It
allows the programmer to write source code in a natural fashion, using
logical words and symbols.
 It is a programming language with strong abstraction from the details of
the computer.
 It is a programming language designed to simplify computer programming.
High-level source code contains easy-to-read syntax that is later
converted into a low-level language, which can be recognize and run by a
specific CPU.
 It is a programming language such as C, FORTRAN, and Pascal that
enables a programmer to write programs that are more or less
independent of a particular type of computer.
 It is considered high-level because they are closer to human language and
further from machine languages.

2. Low Level Language

 It is a programming language that provides little or no abstraction of


programming concepts and is very close to writing actual machine
instructions.
 It is a type of programming language that contains basic instructions
recognized by a computer. It is often cryptic and not human-readable.
 It is used to write programs that relate to the specific architecture and
hardware of a particular type of computer. They are closer to the native
language of a computer which is called binary, making them harder for
programmer to understand.
 It is a programming language that deals with a computer’s hardware
components and constraints. Their prime function is to operate, manage
and manipulate the computing hardware and component.
 It can convert to machine code without a compiler or interpreter.

Two types of low-level language

1. Assembly language
 It is one step closer to a high-level language than machine language. It
includes command such as MOV (move), ADD (add) and SUB (subtract).
These commands perform basic operations, such as moving values into
memory registers and performing calculations,
 It can be converted to the machine language using an assembler.
 It is easy to distinguish from a high level language as it contains few
recognizable human words but plenty of mnemonic code.
 It is second – generation language provides one abstraction level on top of
the machine code.

2. Machine code language


 It also called object code.
 It is a collection of binary digits or bits that the computer reads and
interprets. It is the only language a computer is capable of understanding.
 It is used to directly control a computer’s central processing unit (CPU).
Each instruction causes the CPU to perform a very specific task, such as
load, a store, a jump or an arithmetic logic unit (ALU) operation on one or
more units of data in the CPU’s register or memory
 It is the set of symbolic instruction codes usually in binary form that is
used to represent operations and data in a machine.

History of Programming Language

Now that we know that computers are machines that were created to manipulate
data, it can also process and store data and make it useful information. It was made of
set of instructions to act in a pre-determine way, but the question is how does it all
start? Why it is created and what are the purposes they have created this kind of
programming languages.

We all know that the first computing machine created was the ABACUS who was
created by Babylonia in 2400 B.C. it was first used in China around 500 B.C to perform
basic arithmetic operations such as multiply, divide and calculate square and cube roots
by moving rods around and placing them in specially constructed boards. Then the rest
is history. Many aspiring programmers created basic programing languages and
machine to help peoples work at ease.

Napier’s Bone (1600)


 Invented by John Napier in 1617
 It is a calculating device that allowed the user to carry out multiplication and
division.
 Also known as Napiers rod, are rods which can be used to perform multiplication
of any number by a number 2-9. By placing “bones” corresponding to the digits of
multiplicand next to it to the right.

Pascaline (1642)
 It is a mechanical calculator invented by Blaise Pascal in the mid-17th century.
 It is also called Arithmetic Machine.
 It is the first calculator or adding machine to be produced in any quantity and
actual used.
 It was invented by Blaise Pascal for his father, a tax collector
Difference Engine (1812)
 It is an early calculating machine, verging on being the first computer, designed
and partially built during the 1820’s and 30’s by Charles Babbage
 It is an automatic mechanical calculator designed to tabulate polynomial
functions. Its name is derived from the methods of divided difference.
 It is design to calculate, tabulate polynomial function.

Charles Babbage (December 23, 1791 – October 18, 1971)


 A mathematician, philosopher.
 He is the father of the computer.
 Invented mechanical computer, Analytical Engine and difference engine.

Ada Lovelace (December 10 1815 – November 27 1852)


 Also known as Agusta Ada King, Countess of Lovelace.
 An English mathematician and writer
 She is the first computer programmer

Hollerith’s Tabulator (1890)


 Developed by Herman Hollerith, a Census Bureau statistician.
 It was the first automatic data processing system.
 It was first used to count the U.S census of 1890

Vacuum Tube (1906)


 It is a glass tube that has its gas to remove, creating a vacuum.
 It contains electrodes for controlling electron flow and was used in early
computers as a switch or an amplifier.
 It is a device used to control the flow of electric current using a vacuum in a
sealed container, which usually takes the form of a glass tube.
Harvard Mark I
 It was a general purpose electromechanical computer that was used in the war
effort during the last part of World War II.
 It was the IBM Automatic Sequence Controlled Calculator by Harvard University
staff.
 Developed by Howard Aiken and it was a room sized, relay-based calculator.

Eniac (Electronic Numerical Integrator and Computer)


 Invented year February 1946 by John Presper Eckert and John Mauchly at the
University of Pennsylvania.
 It was the world’s first digital electronic computer.
 It was designed and built for the United States Army to calculate artillery firing
tables. It was its power and general-purpose programmability that excited the
public’s imagination.

Modern Computer
 The principle of the modern computer was proposed by Alan Turing in his
seminal 1963 paper. He proposed a simple machine that he called “Universal
Computing Machine” that is now known as a Universal Turing Machine.
 The fundamental concept of Turing’s design is the stored program, where all the
instructions for computing are stored in the memory.
 The Manchester Baby was the world’s first stored-program computer. It was built
at the Victoria University of Manchester by Frederic C. Williams, Tom Kilburn and
Geoff Tootill and ran its first program on June 21 1948

Wh
1. at
Do Iyou see yourself being one of those who we call programmer?
2. If you become a programmer, what kind of program or application are you going
hav
to create and what will be its purpose?
e
3. Can
today?
you explain the difference of technology before compare to our technology

4.lear
If you are about to re develop any application existing what application is it?

ned
I. ?IDENTIFICATION Write the corresponding correct answers on the space
provided.

________1. It was designed and built for the United States Army to calculate
artillery firing tables. It was its power and general-purpose
programmability that excited the public’s imagination.

________2. He is the father of the computer.

________3. It is the art and science of creating or translating a set of ideas into a
program. It involves coding, modeling, simulating or presenting the
solution to a problem by presenting facts, data or information using
pre-determined rules semantics on a computer or any other device
for automation.

________4. He proposed a simple machine that he called “Universal Computing


Machine” that is now known as a Universal Turing Machine.

________5. It is the first calculator or adding machine to be produced in any


quantity and actual used.

________6. It is a person who writes computer program.

________7. It is second – generation language provides one abstraction level on


top of the machine code
________8. It is a programming language designed to simplify computer
programming. High-level source code contains easy-to-read syntax
that is later converted into a low-level language, which can be
recognize and run by a specific CPU.

________9. She is an English mathematician and writer

________10. It is a programming language that deals with a


computer’shardware components and constraints. Their prime function
is tooperate, manage and manipulate the computing hardware and
component

________11. It was developed by Howard Aiken and it was a room sized, relay
based calculator.

________12. It is a device used to control the flow of electric current using a


vacuum in a sealed container, which usually takes the form of a
glass tube.

________13. It is a programmable electronic device designed to accept data,


perform prescribed mathematical and logical operations at high
speed, and display the results of these operations.

________14. It is used to directly control a computer’s central processing unit


(CPU). Each instruction causes the CPU to perform a very specific
task, such as load, a store, a jump or an arithmetic logic unit (ALU)
operation on one or more units of data in the CPU’s register or
memory

________15. It is a calculating device that allowed the user to carry out


multiplication and division.

________16. It was the first automatic data processing system.

________17. It is the system software that manages computer hardware,


software resources and provides common services for computer
program.

________18. It is an automatic mechanical calculator designed to tabulate


polynomial functions. Its name is derived from the methods of
divided difference.

________19. it was first used in China around 500 B.C to perform basic
arithmetic operations such as multiply, divide and calculate square
and cube roots by moving rods around and placing them in
specially constructed boards
________20. It is a formal language comprising a set of instructions that produce
various kinds of output.it is used in computer programming to
implement algorithms.

II. True or False. Write T on the space provide if the statement is true otherwise write F
if the statement is false.

_________1. High- Level language is a programming language with strong abstraction


from the details of the computer.

_________2. Eniac was invented year February 1946 by John Presper Eckert and John
Mauchly at the University of Pennsylvania
_________3. Lady Ada Lovelace was also known as Agusta Ada King, Countess of
Lovelace.

_________4. Difference Engine was design to calculate, tabulate polynomial function.

_________5. Vacuum Tubes was a glass tube that has its gas to remove, creating a
vacuum.

_________6. Hollerith’s Tabulator was the first automatic data processing system.

_________7. Pascaline was invented by Blaise Pascal for his father, a tax collector

_________8. Modern Computer was the world’s first stored-program computer. It was
built at the Victoria University of Manchester by Frederic C. Williams, Tom
Kilburn and Geoff Tootill and ran its first program on June 21 1948

_________9. Napiers Bone was invented by John Napier in 1617

_________10. Low level language was the set of symbolic instruction codes usually in
binary form that is used to represent operations and data in a machine.

II. Matching Type. Match the values from column A to column B. Write the
correct answer on the space Provided.

_____1. Hollerith Tabulator a.

_____2. Harvard Mark 1 b.


_____3. Difference Engine c.

_____4. Turing Machine d

_____5. Vacuum Tubes e

_____6. Eniac f

_____7.Napiers Bone g

_____8.Manchester Baby h

_____9. Abacus i.

_____10. Pascaline j

You might also like