CP 2 Lesson 1
CP 2 Lesson 1
CP 2 Lesson 1
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
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?
What is Program?
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?
What is programmer?
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.
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.
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.
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.
________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.
________11. It was developed by Howard Aiken and it was a room sized, relay
based calculator.
________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.
_________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.
_________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
_________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.
_____6. Eniac f
_____7.Napiers Bone g
_____8.Manchester Baby h
_____9. Abacus i.
_____10. Pascaline j