0% found this document useful (0 votes)
48 views98 pages

Introduction to Computer Basics and Functions

Uploaded by

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

Introduction to Computer Basics and Functions

Uploaded by

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

Introduction to Computers & its applications

What is Computer?

DEFINITION NO 1:

Computer is an electronic device which takes some input, process it, and produce output.

DEFINITION NO 2:

Electronic machine operating under the control of instructions stored in its own memory
• Accepts data
• Manipulates data
• Produces results
• Stores results

PARTS OF COMPUTER:
According to above definition we can divide computer functionality in to three main parts

• Input
• Output
• Process

INPUT PROCES
OUTPUT
S

INPUT

Input is any data or instructions entered to the computer. Input can be in the form of audio, video,
graphics and animations and instructions. Instructions can be

• Programs
• Commands
• User response
Programs

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
Program tells a computer what to do and how to do? These are written instructions in some
specific language

Commands

Command causes a program to perform a specific action. Like Ctrl+S for saving an [Link]
Document

User Response

A user response is an action which is or can be done by answering any question from computer
like You want to save that file? User have two options Yes or No, that is depend on the user what
to response

PROCESS

Computer data processing is any process that uses a computer program to enter data and
summarize, analyze or otherwise convert data into usable information. The process may be
automated and run on a computer. It involves recording, analyzing, sorting, summarizing,
calculating, disseminating and storing data. Because data is most useful when well-presented and
actually informative, data-processing systems are often referred to as information systems. In
computer processing is done by CPU (Central Processing Unit)

OUTPUT

Output is the data that has been processed in to useful form. The computer takes the input from
user process it and produced output. Output also can be text, Audio, Video, graphics and
animations. Output can be in two forms

• Soft Copy
• Hard Copy Soft Copy:

When you are writing a document, playing a game, watching a video clip, or reading the latest
news. Soft copy is what you see on the monitor (Screen). Soft copy is temporary; after you have
finished with it, there is nothing solid to hold. You can, however, transfer soft copy to a disk to
transport it

Hard Copy:

Hard copy can be touched and carried. Hard copy is usually some form of paper output. It is
especially helpful if you need to have a colleague look at your work or you need to give your
work to a supervisor or teacher.
COMPONENTS OF COMPUTER
There are three main Components of computer.

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications

1. Input devices
2. CPU
3. Output Devices

INPUT CPU
OUTPUT
DEVICES DEVICES

INFORMATION PROCESS CYCLE


Computer process data (input) into information (output).A Computer often holds data,
information, and instruction in storage for future use. The series of input, process, output
and storage activities as the information process cycl.

DATA INFORMATION

INPUT CPU OUTPUT

INSTRUCTION

STORAGE
MEDIUM

WHAT IS DATA?
Definition: ―Raw facts, figures, events and transactions are called data‖

Example:

• Researchers who conduct market research survey might ask member of the public to
complete questionnaires about a product or a service. These completed questionnaires are
data.
• NADRA prepared CNIC of Pakistanis by collecting data of people who belongs to
Pakistan.
• Some candidates want to take admission in university they will fill admission forms.

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
Above all are unprocessed and unprepared which is needed to process and work more.

WHY WE NEED DATA

• Facts, statistics used for reference or analysis.

• Numbers, characters, symbols, images etc., which can be processed by a computer.


• Data must be interpreted, by a human or machine, to derive meaning
• "Data is a representation of information" *

WHAT IS INFORMATION?

DEFINATION:

• ―Meaning full data is called information‖


• ―Processed data is called information‖

WHY WE NEED INFORMATION

• Knowledge derived from study, experience (by the senses), or instruction.


• Communication of intelligence.
• "Information is any kind of knowledge that is exchangeable amongst people, about
things, facts, concepts, etc., in some context."
• "Information is interpreted data"

DATA PROCES
INFORMATION
S

COMPONENTS OF COMPUTER
INPUT DEVICES
WHAT IS INPUT?

Input is any data or instructions entered to the computer. Input can be in the form of audio, video,
graphics and animations and instructions

WHAT ARE INPUT DEVICES?

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
Any hardware component used to enter data, programs, commands, and user responses into a
computer

Examples

• Key Board
• Mouse
• Digital Camera
• Webcam
• Scanner etc

WHAT IS HARDWARE?

The term hardware refers to the physical parts of the computer. Computer hardware is versatile-
what it does depends on the computer program you use. All components which are tangible
(touchable) are called Hardware

Examples: Mic, Keyboard,Hard Disk, Scanner, Printer etc

WHAT IS SOFTWARE?

Software is the set of instructions (also called a program) that guides the hardware through its
job. That tells the computer what to do? And how to do it? All components which are non
tangible (Not Touchable) are called software.

Examples: Ms Office, Operating Systems, Adobe photo shop etc

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications

1) KEYBOARD

Definition:

―Keyboard is an input device, that contain keys user press to enter data or instructions in to the
computer‖.

You enter most input data into the computer by using a keyboard. This input method is similar to
typing on a typewriter.

KEYS OF KEYBOARD

Computer keyboards include keys that are designed to perform specific tasks. These keys enable
the user to perform complex tasks easily when using the application. For example, many
applications use a function key to access online help for the user.

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications

Keyboard keys consist of

• Alphabetic keys
• Numerical keys
• Symbols
• Functional keys
• Extra keys

Alphabetic keys contain alphabets from A-Z & a-z

Numerical keys contain numbers 0-9

Symbols keys contain many symbols like !, @, #, $, % etc

Functional keys contain f1-f12, design for special purpose will discuss latter.

Extra keys contain Esc, Alt, Ctrl, Backspace, Enter etc

2) POINTING DEVICES

Definition:

A pointing device is an input device which is used to control a pointer on a screen. Pointer is a
small symbol on a screen.

A pointing device is an input interface (specifically a human interface device) that allows a user
to input spatial (i.e., continuous and multi-dimensional) data to a computer. CAD systems and
graphical user interfaces (GUI) allow the user to control and provide data to the computer using
physical gestures — point, click, and drag — for example, by moving a hand-held mouse across
the surface of the physical desktop and activating switches on the mouse. Movements of the
pointing device are echoed on the screen by movements of the pointer (or cursor) and other
visual changes.

MOUSE
Definition:

―Mouse is an input device that fits under palm of hand and Controls movement of pointer, also
called mouse‖

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
The mouse is a palm-size device with a ball built into the bottom. The
mouse is usually connected to the computer by a cable (computer wires are
frequently called cables) and may have from one to four buttons (but
usually two). Mouse come in many shapes and sizes. When you move the
mouse over a smooth surface, the ball rolls, and the pointer on the display
screen moves in the same direction.

With the mouse, you can draw, select options from a menu, and modify or move text. You issue
commands by pointing with the pointer and clicking a mouse button. In addition to minimizing typing
errors, a mouse makes operating a microcomputer easier for beginning.

TYPES OF MOUSE

There are three types of mouse

1. Mechanical mouse
2. Optical mouse
3. Wireless mouse

MECHANICAL MOUSE:

The mouse that contains a metal or rubber ball on its under side. When the ball is rolled in any
direction, sensors inside the mouse detect this motion and move the on-screen mouse pointer in
the same direction (picture above).

OPTICAL MOUSE:

An optical mouse uses a light-emitting (laser) to detect movement relative to the underlying
surface.

WIRELESS MOUSE:

Wireless mice usually work via radio frequencies commonly referred to as RF. RF
wireless mice require two components to work properly a radio transmitter and a
radio receiver.
JOY STICK
A joystick is a pointing device often used for playing games. The
joystick has a gearshift-like lever that is used to move the pointer on
the screen. On most joysticks, a button on the top is used to select
options. In industry and manufacturing, joysticks are used to control
robots. Flight simulators and other training simulators also use
joysticks.

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications

TRACKBALL

A trackball is like an upside-down mouse. Used similarly to the mouse, the trackball is
frequently attached to or built into the keyboard.

The main advantage of a trackball is that it requires less desk space than a mouse. (Some
individuals in the computer industry believe that the mouse will soon be replaced by devices that
do not require as much space to use.)

The mouse is not practical for people using a laptop computer in a small space. Early
alternatives, such as trackballs clipped to the side of the keyboard, have not proved satisfactory.
The IBM ThinkPad replaces the trackball with a red plastic button, called a track point, located
in the middle of the keyboard. You move the button with your thumbs.

TOUCHPAD

A touch pad is a device for pointing (controlling input positioning) on a computer display screen.
It is an alternative to the mouse. Originally incorporated in laptop computers, touch pads are also
being made for use with desktop computers. A touch pad works by sensing the user's finger
movement and downward pressure.

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications

TOUCHSCREEN
A touch screen is a computer display screen that is also an input
device. The screens are sensitive to pressure; a user interacts
with the computer by touching pictures or words on the screen.

DIGITAL PEN
A digital pen is a battery-operated writing instrument that
allows the user to digitally capture a handwritten note or
drawing. Typically, a digital pen comes with a Universal Serial
Bus (USB) cradle to let the user upload the handwritten notes
to a personal computer (PC).
The pen looks like a regular ball-point pen and can be used as such,
but requires special digital paper if the user wishes to digitally
capture what he has written. A page of digital paper, which can be
purchased in traditional pad or sticky-note size, has small dots on it
that allow the pen to "see" what has been written.

LIGHT PEN
A light-sensitive stylus wired to a video terminal used to draw
pictures or select menu options. The user brings the pen to the
desired point on screen and presses the pen button to make contact. Contrary to
what it looks like, the pen does not shine light onto the screen; rather, the screen
beams into the pen. Screen pixels are constantly being refreshed. When the user
presses the button, the pen senses light, and the pixel being illuminated at that
instant identifies the screen location.
3) BIOMETRIC DEVICES
A "biometric device" is any device that measures a biological function or trait. it identifies
persons seeking access to a computing system by determining their physical characteristics
through fingerprints, voice recognition, retina patterns, pictures, weight, or other means. 4)
MIC/ HEAD PHONE Both are input devices which are related to audio input. These
Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
device is used to enter sound in to the system for processing. It can be used in chatting, video
conferencing, music or whenever we want to interact with the computer from voice input.

5) DIGITAL CAMERA
A digital camera can be used to take pictures. It can be hooked up
to a computer to transfer the pictures from the camera to the
computer. it use light sensitive processing chip to capture pictures
or images

We can save these images where ever we want can be a CD,


Computer disk, USB drive or can transfer from one computer to
other computer or device.

6) DIGITAL SCANNER
A scanner is used to copy pictures or other things and save them as
files on the computer. A scanner is similar to a photocopier, except
that instead of producing a paper copy of the document you place
on it, you get an electronic copy which appears on your computer
screen. This is very important input device use to convert a
hardcopy file (printed paper) to a softcopy (image or display file).

COMPONENTS OF COMPUTER
OUTPUT DEVICES
WHAT IS OUTPUT?

An output is the data that has been processed in that form which is useful by user or machine for future
processing. Output can be in two forms Soft Copy and Hard Copy. (Describe further)

WHAT ARE OUTPUT DEVICES?

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
Any hardware component used to show results after processing to any user and it use to send the
results of processing to the user. Output can be text, Audio, Video & graphics.

Examples
• Monitor
• Printer
• Plotter
• Projectors
• Speakers
• Headphone etc

MONITOR/DISPLAY DEVICES

Definition:

―Monitor or display devices are used to get output on screen. It is like small television and
available in different sizes and specifications. The text which is displayed on screen is called
softcopy (as defined above)‖

TYPES OF MONITOR

There are majorly two type of monitor according to its specification. These are

• Monochrome monitor
• Color monitor

Prepared by [Link], Assistant Professor, Department of BCA, Bon Secours College for Women, TNJ
Introduction to Computers & its applications
MONOCHROME MONITOR

Monochrome monitor is based on a single color that can be white, blue, black or gray etc. these
type of monitors is same like the old mobile phones which have a single color in back ground
with black text in display. That is very much useful in these devices where we need simple
display. Like some ATM machines, mobile phones, specific digital devices like PDA, pagers etc

COLOR MONITOR

Color monitor is such monitor which is based on colors as its name implies. Today mostly
monitor are based on color display rather it is flat panel or tube based monitors. The basic colors
in that monitors are three which are RGB stands for Red, Blue, Green by these basic colors a
monitor can generate many other colors by the combination of these basic colors.

2. PRINTERS

The second most common form of computer output is printed documents. Although a computer
can operate perfectly without a printer, it is certainly helpful to the user to have one. People often
prefer to get printouts of the work they have done rather than to look at it on the screen it is
considered a form of hard copy.

Types:
Printer has majorly two types.

• Impact printers
• Non impact printers
Introduction to Computers & its applications

3. PLOTTERS
A plotter, like a printer, produces hard -copy output. Plotters,
which produce high-quality color graphics, are usually
categorized by whether they use pens or electrostatic charges to
create images. A continuous -curve plotter is used to draw maps
from stored data. Comput er-generated maps can be retrieved and
plotted or used to show changes over time. Plotters are generally
more expensive than printers, ranging from about 100,000 to
$750,000 (or even more).

4. SPEAKERS/ HEADPHONE

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 13

Speakers and headset is used to get audio output. A system's speaker is the component that takes
the electronic signal stored on things like CDs, tapes and DVDs and turns it back into actual
sound that we can hear. In any sound system, ultimate quality depends on the speakers. The best
recording, encoded on the most advanced storage device and played by a top-of-the-line deck
and amplifier, will sound awful if the system is hooked up to poor speakers.

MULTIMEDIA/PROJECTORS

A Digital Projector/Multimedia is an electo-optical machine which converts image data from a


computer or video source to a bright image which is then imaged on a distant wall or screen
using a lens system. The cost of a device is not only determined by its resolution, but also by its
brightness. The projector serves the following purposes:

• Visualization of data stored in a computer for presentations


• Demonstration of program products for a large number of
prospective customers
• The projector replaces the white board as well as written
documents.
• Watching moving images from a video tape player or
digital video disk player.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 14


Introduction to Computers & its applications
• Digital projectors may also be built into cabinets which use a rear projection screen to
form a single unified display device, now popular for "home theater" applications.

CENTRAL PROCESSING UNIT

The CPU stands for Central Processing Unit, is the part of a computer system that is commonly
referred to as the "brains" of a computer. The CPU is also known as the ―processor‖
or ―microprocessor‖.
The CPU is responsible for executing a sequence of stored instructions called a program. The
programs tells a computer what to do and how to do? This program will take inputs from an
input device, process the input in some way and output the results to an output device.

INPUT PROCES
OUTPUT
S

CPU/Processor

CPUs aren’t only found in desktop or laptop computers, many electronic devices now rely on
them for their operation. Mobile phones, DVD players and washing machines are examples of
equipment that have a [Link] is located in motherboard. The speed of processing of CPU is
about 500 MHz to 2.5 GHz.

PARTS OF CPU

CPU is subdivided in to three parts defined below:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 15


Introduction to Computers & its applications
1. ALU
2. CU
3. Register

Arithmetic & Logical Unit


CPU

ALU
CU
Control Unit

ARITHMETIC & LOGICAL UNIT


ALU stands for ―Arithmetic and Logical unit‖. This unit of the CPU is capable of
performing arithmetic and logical operations. This unit of the CPU gets data from the computer memory
and perform arithmetic and logical operations on it.

ALU is further divided in to two parts, Arithmetic unit & Logical unit.
ARITHMETIC UNIT:
The arithmetic unit of ALU performs arithmetic operations like addition, multiplication, subtraction and
division.

LOGICAL UNIT:
The Logical unit of ALU performs logical operations such as comparison of two numbers. It tells us
which number is greater and which is smaller. The common comparisons such as less than, equal to, or
greater than are performed by the logical unit.

REGISTERS:
A processor has its own memory inside it in the shape of small cells. Each memory cell is called
a "Register". Registers are used to carry data temporarily for performing operations. There are
total 13 registers in a processor. ALU gets data from registers and stores it in registers to perform
arithmetic and logical operations. And data comes in registers from main memory of the
computer.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 16


Introduction to Computers & its applications

1) CONTROL UNIT
This unit of the processor controls all the activities of the processor and also controls the input
and output devices of the computer. It acts just like a police inspector who controls the traffic on
a road.

The control unit controls the whole traffic of the computer. It tells the input device that it is now
his turn to feed data in the computer and show result of data after execution on the output units.
This unit also controls the flow of instructions, which are given to a computer.

It obtains instructions from the program stored in main memory, interprets (translation of
instructions into computer language) the instructions, and issues signals that cause other units of
the computer to execute them
WORKING COLLECTING

ALU
INPUT OUTPUT
CU
Registers

PRIMARY MEMORY

The primary memory or the main memory is part of the main computer system. The processor or
the CPU directly stores and retrieves information from it. This memory is accessed by CPU, in
random fashion. That means any location of this memory can be accessed by the CPU to either
read information from it, or to store information in it.

There are two types of memory CPU

1. RAM
2. ROM
RANDOM ACCESS MEMORY (RAM)

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 17


Introduction to Computers & its applications
RAM is used to store programs and data that are being used by the computer. When the computer
is turned on the RAM is empty. Data and programs can be put into RAM from either an input
device or backing store.

The data in RAM is lost when the computer is turned off so it is known as Volatile Memory. To
keep data the user must save it to backing store before the
computer is turned off.
RAM is further divided in to two types

• DRAM (Dynamic Random access Memory)

• SRAM (Static Random access Memory)


DRAM
DRAM stands for Dynamic RAM. A type of physical memory used in most personal computers.
The term dynamic indicates that the memory must be constantly refreshed (reenergized) or it will
lose its contents. RAM is sometimes referred to as DRAM (pronounced dee-ram) to distinguish
it from static RAM (SRAM). Static RAM is faster and less volatile than dynamic RAM, but it
requires more power and is more expensive.

SRAM
SRAM stands for Static RAM. Short for static random access memory, and pronounced ess-ram.
SRAM is a type of memory that is faster and more reliable than the more common DRAM
(dynamic RAM). The term static is derived from the fact that it doesn't need to be refreshed like
dynamic RAM

READ ONLY MEMORY (ROM)

The contents of ROM are permanent. It cannot be altered by the user. The content is written onto
the ROM when it is first made. ROM keeps its contents even when the computer is turned off
and so is known as Non-Volatile Memory.

On some computers a special piece of software called the operating system is stored in ROM.
ROM is also often used in embedded systems where a small built-in computer is used to control
a device such as a washing machine. The program that controls the machine is stored on ROM.

TYPES OF ROM
ROM is further divided in to three types

• PROM (Programmable Read-Only Memory)


• EPROM (Erasable Programmable Read-Only
Memory)

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 18


Introduction to Computers & its applications
• EEPROM (Electronically Erasable
Programmable Read-Only Memory)

PROM
PROMs are manufactured as blank chips on which data can be written with a special device
called a PROM programmer.

EPROM
A rewritable memory chip that holds its content without power. EPROM chips are written on an external
programming device before being placed on the mother board.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 19


Introduction to Computers & its applications

EEPROM
A rewritable memory chip that holds its content without power. EEPROMs are typically used on
circuit boards to store small amounts of instructions and data.

GENERATIONS OF COMPUTER
The history of computer development is often referred to in reference to the different generations
of computing devices. A generation refers to the state of improvement in the product
development process. This term is also used in the different advancements of new computer
technology. With each new generation, the circuitry has gotten smaller and more advanced than
the previous generation before it.

As a result of the miniaturization, speed, power, and computer memory has proportionally
increased. New discoveries are constantly being developed that affect the way we live, work and
play.

Each generation of computers is characterized by major technological development that


fundamentally changed the way computers operate, resulting in increasingly smaller, cheaper,
and more powerful and more efficient and reliable devices.

Read about each generation and the developments that led to the current devices that we use
today. The generations which are divided in to fifth categories can be describe as:

Generations Period Technology

First Generation 1942-1955 Vacuums Tube


Second Generation 1955-1964 Transistors
Third Generation 1964-1975 Integrated Circuits (ICs)
Forth Generation Since 1975 Microprocessor/Large Scale
Integration
Fifth Generation Since 1980 Artificial Intelligence

FIRST GENERATION (1942 - 1955)

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 20


Introduction to Computers & its applications
The first computers used vacuum tubes for circuitry and magnetic drums for memory, and were
often enormous, taking up entire rooms. First generation computers relied on machine language
to perform operations, and they could only solve one problem at a time.

The Mark-I, EDSAC, EDVAC, UNIVAC-I and ENIAC computers are examples of first-
generation computing devices. It was very expensive to operate and in addition to using a great
deal of electricity, generated a lot of heat, which was often the cause of malfunctions.

Vacuum tubes used to calculate and store information, these computers were also very hard to
maintain. First generation computers also used punched cards to store symbolic programming
languages. Most people were indirectly affected by this first generation of computing machines
and knew little of their existence.

IMPORTANT MACHINES:
Mark-I, EDSAC, EDVAC, UNIVAC-I and ENIAC

ADVANTAGES:

1. After long history of computations, the 1G computers are able to process any tasks in
milliseconds.
2. The hardware designs are functioned and programmed by machine languages (Languages
close to machine understanding).
3. Vacuum tube technology is very much important which opened the gates of digital world
communication.

DISADVANTAGES:

1. Size of that machines are very big


2. Required large amount of energy for processing

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 21


Introduction to Computers & its applications

3. Very expensive
4. Heat generated and need air conditioning.
5. Not portable ( never take from one place to other)
6. Comparing with 5G computers, these computers are slow in speed.
7. Not reliable
8. In order to get proper processing, maintenance is required continuously.

SECOND GENERATION (1942 - 1955)

Transistors replaced vacuum tubes and ushered in the second generation computer. Transistor is
a device composed of semiconductor material that amplifies a signal or opens or closes a circuit.
Invented in 1947 at Bell Labs, transistors have become the key ingredient of all digital circuits,
including computers. Today's latest microprocessor contains tens of millions of microscopic
transistors.

Prior to the invention of transistors, digital circuits were composed of vacuum tubes, which had
many disadvantages. They were much larger, required more energy, dissipated more heat, and
were more prone to failures. It's safe to say that without the invention of transistors, computing
as we know it today would not be possible.

The transistor was invented in 1947 but did not see widespread use in computers until the late
50s. The transistor was far superior to the vacuum tube, allowing computers to become smaller,
faster, cheaper, more energy-efficient and more reliable than their first-generation predecessors.
Though the transistor still generated a great deal of heat that subjected the computer to damage,
it was a vast improvement over the vacuum tube. Second-generation computers still relied on
punched cards for input and printouts for output.

Second-generation computers moved from cryptic binary machine language to symbolic, or


assembly, languages, which allowed programmers to specify instructions in words. High-level

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 22


Introduction to Computers & its applications
programming languages were also being developed at this time, such as early versions of
COBOL and FORTRAN. These were also the first computers that stored their instructions in

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 23


Introduction to Computers & its applications
their memory, which moved from a magnetic drum to magnetic core technology. The first
computers of this generation were developed for the atomic energy industry.

IMPORTANT MACHINES:
IBM 7074 series, CDC 164, IBM 1400 Series.

ADVANTAGES:

1. If we compare it with G1 computer, less expensive and smaller in size.


2. Fast in speed
3. Less head generated as G1 computers generate more.
4. Need low power consumption
5. Language after machine language for programming, in G2 assembly language (COBOL,
FORTRON) is introduced for programming.
6. Portable.
DISADVANTAGES:

1. Maintenance of machine is required.


2. Air conditioning required still as heat causes to process slowly.
3. These computers are not used as personal system.
4. Preferably used for commercial purposes

THIRD GENERATION (1964 - 1975)


The development of the Integrated Circuit was the hallmark of the third generation of
computers. Transistors were miniaturized and placed on silicon chips, called semiconductors,
which drastically increased the speed and efficiency of computers.

Instead of punched cards and printouts, users interacted with third generation computers through
keyboards and monitors and interfaced with an operating system, which allowed the device to
run many different applications at one time with a central program that monitored the memory.
Computers for the first time became accessible to a mass audience because they were smaller
and cheaper than their predecessors.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 24


Introduction to Computers & its applications

IMPORTANT MACHINES:
IBM System/360 & IBM 370, PDP-8, DEC, UNIVAC 1108, UNIVAC 9000.

ADVANTAGES:
1. Smaller in size
2. Low cost then previous
3. Low power consumption
4. Easy to operate
5. Portable
6. Input devices introduced and that make user easy to interact with it like keyboard, mouse
etc
7. External Storage medium introduced like floppy & tape.

DISADVANTAGES:

1. IC chips are still difficult to maintain


2. Need complex technology.

FOURTH GENERATION (1975 ONWARDS)

The Microprocessor brought the fourth generation of computers, as thousands of integrated circuits were built onto
a single silicon chip. What in the first generation filled an entire room could now fit in the palm of the hand.

The Intel 4004 chip, developed in 1971, located all the components of the
computer—from the central processing unit and memory to input/output
controls—on a single chip.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 25


Introduction to Computers & its applications
In 1981 IBM introduced its first computer for the home user, and in 1984 Apple introduced the
Macintosh. Microprocessors also moved out of the realm of desktop computers

and into many areas of life as more and more everyday products began to use microprocessors.

networks , which
As these small computers became more powerful, they could be linked together to form
eventually led to the development of the Internet. Fourth generation computers also saw the
development of GUIs, the mouse and handheld devices.
IMPORTANT MACHINES:
Intel processors, AMD processor based machines

ADVANTAGES:
1. Smaller in size
2. High processing speed
3. Very reliable
4. For general purpose
5. More external storage mediums are introduced like CD-ROM, DVD-ROM.
6. GUIs developed for interaction

FIFTTH GENERATION (1980 ONWARDS)

Fifth generation computing devices, based on Artificial Intelligence, are still in development,
though there are some applications, such as voice recognition, that are being used today.

The use of parallel processing and superconductors is


helping to make artificial intelligence a reality. Quantum
computation and molecular and nanotechnology will
radically change the face of computers in years to come.

The goal of fifth-generation computing is to develop


devices that respond to natural language input and are
capable of learning and self-organization.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 26


Introduction to Computers & its applications

IMPORTANT MACHINES:
ULAIC Technology, Artificial intelligence etc

PROPERTIES
1. Program independent
2. Have thinking and analysis by its own
3. Voice reorganization & biometric devices
4. Self organization and learning

TYPES OF COMPUTER

The computer sitting on the desk in your classroom is a microcomputer. It is a small, powerful
piece of equipment. Even so, the power of the microcomputer is not enough for most large
organizations. The computer industry consists of more than just microcomputers.

Any classification of computers is somewhat arbitrary. Computer can be classified it to following


basis defined below.

• On the basis of functionality


• On the basis of Size, Speed and Cost.
ON THE BASIS OF FUNCTIONALITY:

According to functionality computer can be divided in to three types:

1. Analog
2. Digital
3. Hybrid

ANALOG COMPUTERS:

DEFINITION:

• ―An analog (spelled analogue in British English) computer is a form of computer


that uses the continuously-changeable aspects of physical fact such as electrical,
mechanical, or hydraulic quantities to model the problem being solved.‖
• Analog means continuity of associated quantity just like an analog clock measures time
by means of the distance traveled by the hand of the clock around a dial.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 27


Introduction to Computers & its applications

HISTORY:

Mechanical analog computers were very important in gun


fire control in World War II and the Korean War; they
were made in significant numbers. In particular,
development of transistors made electronic analog
computers practical, and before digital computers had
developed sufficiently, they were commonly used in
science and industry.

EXAMPLES:

• Thermometer
• Analog clock
• Speedometer
• Tire pressure gauge

ADVANTAGES:

• Analog computer has come to refer to o devices and media that represent o Store
images o Sound, motion pictures, etc.

DISADVANTAGES:

• Analog computers can have a very wide range of complexity.


• Slide rules and monographs are the simplest, while naval gun fire control computers and
large hybrid digital/analogue computers were among the most complicated.  Very
complicated for containing output for the users some time.

DIGITAL COMPUTERS:

DEFINITION:

• ―A computer that performs calculations and logical operations with quantities


represented as digits, usually in the binary number system of ―0‖ and ―1‖.
• ―Computer capable of solving problems by processing information expressed in discrete
form. By manipulating combinations of binary digits (“0”, “1”), it can perform
mathematical calculations, organize and analyze data, control industrial and other
processes, and simulate dynamic systems such as global weather patterns. ‖
HISTORY:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 28


Introduction to Computers & its applications
In 1937 at Bell Labs, George Stibitz invented the first calculator based on binary circuits to
perform complex mathematical formulas.

Steinitz’s invention transformed computer science from analog to digital. With the advent of
digital technology, scientists could customize a computer's operating functions by developing
programming languages.

EXAMPLES:

• IBM PC
• Apple Macintosh
• Calculators
• Digital watches etc

HYBRID COMPUTERS:

DEFINITION:

• ―A computer that processes both analog and digital data‖.


• ―Hybrid computer is a digital computer that accepts analog signals, converts them
to digital and processes them in digital form‖

A hybrid computer may use or produce analog data or digital data.


It accepts a continuously varying input, which is then converted
into a set of discrete values for digital processing.

Examples:

• Hybrid computer is the computer used in hospitals to


measure the heartbeat of the patient.
• Devices used in petrol pump.
• Hybrid Machines are generally used in scientific
applications or in controlling industrial processes.
ON THE BASIS OF SIZE, SPEED AND COST:

We can divide computers on the basis of size cost and speed as:

• Super Computer
• Mainframe Computer
• Mini Computer
• Micro Computer
• Personal Computer

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 29


Introduction to Computers & its applications
o Desktop computers o
Laptop /Note Books
• Mobile Computer & Devices o PDA
o Tablet PC o Hand
Held Computer
o Laptop/Note Books
SUPER COMPUTER

Supercomputers are the largest, fastest, most powerful, and most expensive computers made.
Like other large systems, supercomputers can be accessed by many individuals at the same time.
Supercomputers are used primarily for scientific applications that are mathematically intensive.
The first supercomputer was built in the 1960s for the United States Department of Defense.

This computer was designed to be the world's fastest and most powerful computer of that time.
The commitment to create the fastest, most powerful computer in the world is still the driving
force behind the development of supercomputers. Manufacturers produce relatively few of any
one model of supercomputer, and they spend millions of dollars on research and development of
new machines.
Supercomputers derive much of their speed from the use of multiple processors. Multiprocessing
enables the computers to perform tasks simultaneously--either assigning different tasks to each
processing unit or dividing a complex task among several processing units.

EXAMPLE:

• Cray-1
• Cray-2
• Control Data Cyber 205
• ETA
FEATURES:

• The aerospace, automotive, chemical,


electronics and petroleum industries use
supercomputers extensively.

• Supercomputers are used in weather


forecasting and seismic analysis. They are
found in many public and private research
centers, such as universities and government laboratories.

• A supercomputer was used to alert scientists to the impending collision of a comet with
Jupiter in 1994, giving them time to prepare to observe and record the event.

• The ultra supercomputer will simulate nuclear explosions (eliminating the need to
detonate any bombs), model global weather trends, and design power plants.
Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 30
Introduction to Computers & its applications
• Supercomputers can perform at up to 128 gigaflops, and use bus widths of 32 or 64 bits.
This capability makes supercomputers suitable for processor-intensive applications, such
as graphics.

Note:

The speed of modern supercomputers is measured in nanoseconds and gigaflop. A nanosecond


is one billionth of a second. A gigaflop is one billion floating-point arithmetic operations per
second.
MAINFRAME COMPUTER
Mainframe computers are the most powerful computers. A mainframe computer may contain
several microprocessors. A single mainframe computer can be used by hundreds of people at
once.

Each user has his own terminal that is connected to the mainframe. Mainframe computers are
usually kept in a special cooled, clean computer room. Minicomputers are medium-sized
computers which are more powerful than microcomputers but not as powerful as mainframes.

A mainframe computer system is usually composed of several computers in addition to the


mainframe, or host processor.

Host Processor:

The host processor is responsible for controlling the other processors, all the peripheral devices,
and the mathematics operations.

Front End processor:


A front-end processor is responsible for handling communications to and from all the remote
terminals connected to the computer system.

Back end Processor:

Sometimes a back-end processor is used to handle data retrieval operations. Although the host
computer could perform all these operations, it can be used more efficiently if relieved of time-
consuming chores that do not require processing speed.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 31


Introduction to Computers & its applications

FEATURES:

• Mainframe computer systems are powerful enough to support several hundred users
simultaneously at remote terminals.

• Mainframe Computers are so much faster than people, the users never notice that the
computer is handling other tasks.

• This capability to process many programs concurrently for multiple users is known as
multiprogramming.

• The typical mainframe computer occupies much of a large room.

• Like supercomputers, mainframes require an environment with closely monitored


humidity and temperature.

• Mainframe computers are priced between $100,000 and $2,000,000.

EXAMPLE:

• IBM S/390
• Amdahl 580
• Control Data Cyber 176

MINI COMPUTER

The "age of the mini" started in the late 1960s. The creation of integrated circuits suitable for
computers enabled designers to shrink the size of the computer. Minicomputers are
frequently referred to as mid-range computers.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 32


Introduction to Computers & its applications

Before Digital Equipment Corporation (DEC) released the first DEC PDP-8 minicomputer in
1968, most medium-sized organizations were priced out of the computer market because they
couldn't afford mainframe computers.

FEACTURES:

• Like mainframes, most minicomputers are multiuser systems.

• Many of today's minicomputers can accommodate as many as 200 users working from
individual terminals.

• Mini computers are a little slower than mainframe.

• Like mainframes, minicomputers can accommodate remote users, but not as many.

• Minicomputers' input, output, and storage devices look like those on mainframes.

• Minicomputers have slightly less storage, and the printers are slightly slower.
EXAMPLE:

• IBM AS/400
• IBM SYSTEM 360
• HP 3000
MICROCOMPUTER

When you are working on a multiuser computer, such as a mainframe or minicomputer, you can
control the input and see the output on the display, but you control nothing else.

A single-user computer gives you control over all the phases of computer processing: input,
processing, output, and storage. You can select the programs you want to use, and you don't have
to compete with other users to gain access to the system. A single-user system is designed to
meet the computing needs of an individual.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 33


Introduction to Computers & its applications
Single-user computers fall into two categories:

• Workstations
• Microcomputers.

WORKSTATION:

A workstation is a powerful desktop computer designed to meet the computing needs of


engineers, architects, and other professionals who need detailed graphics displays. The
workstation has sometimes been called a "super micro." The workstation looks very much like a
desktop microcomputer, but the chips inside make the difference

For example, workstations are commonly used for computer-aided design (CAD), in which
industrial designers create pictures of technical parts or assemblies. To process these complex
and detailed diagrams, the computer needs great processing power and much storage.

FEATURES:

• Workstations are small, powerful systems designed to drive networks of less powerful
microcomputers and to create high-quality graphics.

• Workstations typically cost $5,000 to $20,000.

• Major competitors in this market include DEC, Hewlett-Packard, Sun, and Silicon
Graphics,
Inc.
MICROCOMPUTERS:

It is difficult to overstate the impact of the microcomputer on the computer industry. In 1975, the
microcomputer did not exist. In 1995, sales exceeded $116 billion. Microcomputers are the
fastest growing segment of the computer industry.

The microcomputer segment of the industry is complex; there are different types of
microcomputer platforms with varying capabilities. The most common type of microcomputer is
a desktop computer, which is a non portable personal computer that fits on top of a desk.
Microcomputers are the smallest and cheapest of these and are used at home, in schools and in
some businesses. Mainframe computers are the most powerful computers

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 34


Introduction to Computers & its applications

This table makes some comparisons between the different types of computer:

Comparison Microcomputer Minicomputer Mainframe


Medium sized
Home, small
business. e.g. Large
business, on a
Where Used supermarket, businesses,
network in a
traffic control universities.
larger business.
system.
Number of
1 1 - 20 Hundreds
Users
30,000 – 200,000 25,000-100,00 Rs
Cost
Rs Rs 2,000,000+

LAPTOP /NOTE BOOK COMPUTER:

DEFINATION:―A laptop is a personal computer designed for mobile use, small and
light enough to sit on a person's lap while in use.‖

 “A portable computer typically weighing less than 6 pounds (3 kilograms) that has a flat-
panel display and miniature hard disk drives, and is powered by rechargeable
batteries.”

Laptops are capable of many of the same tasks that desktop computers perform, although they
are typically less powerful. Laptops contain components that are similar to those in their
desktop counterparts and perform the same functions but are miniaturized and optimized for
mobile use and efficient power consumption. Laptops usually have LCD displays.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 35


Introduction to Computers & its applications
Laptops generally cost around twice as much as a desktop machine of similar specification.
Performance is always lower than that of a comparable desktop because of the compromises
necessary to keep weight and power consumption low.

MOBILE COMPUTERS / DEVICES

All devices which can carry in hand and portable, is said to be mobile devices and computers.

These Devices are categorized in:

• PDA
• Tablet PC
• Hand Held Computer
• Laptop/Note Books

PDA DEFINITION:

PDA stands for ―Personal Digital Assistant‖. A small, handheld


system combining in one device multiple computing, Internet,
networking, and fax/telephone features‖A PDA contain following
features:

• Keep phone directories


• Calendars and provide calculator capabilities
• Schedule appointments
• Retrieve frequently used phone numbers

• Jot down notes.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 36


Introduction to Computers & its applications
• Most PDAs are designed to accept written input by a pen; the PDA decodes what you
write.

SOFTWARE AND PROGRAMING


LANGUAGES

SOFTWARE:

DEFINITION:

• ―A piece of software is a computer program which has been written to carry out
a particular task.‖

• ―A set of instruction to solve a particular problem‖

Without software the hardware that is used to build a computer system would not be very useful.
A software program contains the instructions that the computer must follow to carry out the task.
Sometimes more than one program is required to complete a task. When this is the case the
group of programs which together complete the task are known as a software package.

Software programs are originally produced by computer programmers who will write the
instructions that form the program in a programming language.

Example pieces of software are:

• A word processor.

• A multimedia encyclopedia.

• A spreadsheet.
TYPES OF SOFTWARE

A software is usually classified as being two types


1. Systems software
2. Applications software.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 37


Introduction to Computers & its applications

SYSTEM SOFTWARE

Systems software controls the operation of a computer. Without systems software a computer
would not function. The most important piece of systems software is the operating system. The
operating system will perform vital tasks such as:

• Managing communications between software and hardware.

• Allocating computer memory to other software programs.

• Allocating CPU time to other software programs.

TYPES

• Operation systems
• Utility program
• Programming languages 
Device drivers

APPLICATION SOFTWARE

DEFINATION:

―Application software consists of programs designed to perform specific tasks for


users‖.

Application software can be used as a productivity/business tool; to assist with


graphics and multimedia projects; to support home, personal, and educational
activities; and to facilitate communications.

TYPES:

• Word Processor
• Presentation Software

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 38


Introduction to Computers & its applications

• Database
• Spreadsheet
• Communication software
• Desktop Publisher
• Graphics Package

SYSTEM SOFTWARE
DEFINATION:

Systems software controls the operation of a computer. Without systems software a computer
would not function. The most important piece of systems software is the operating system. The
operating system will perform vital tasks such as:

• Managing communications between software and hardware.

• Allocating computer memory to other software programs.

• Allocating CPU time to other software programs.

EXAMPLES:

• Operation systems
• Utility program
• Programming languages
• Device drivers

OPERATING SYSTEM

The operating system is a very special piece of software. All the other applications software such
as databases and spreadsheets communicate with the computer hardware through the operating
system. The operating system controls the overall operation of the computer.

DEFINITION:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 39


Introduction to Computers & its applications
―An operating system (or OS) is a computer program which controls the entire operation of the
computer. Computer software applications communicate with the computer hardware via the
operating system‖.
Example Operating Systems

When you buy a computer it is usually supplied with an operating system already installed. You
will not be able to use a computer without an operating system. Different operating systems are
available for different types of computer and different purposes. Some popular operating systems
are

• Microsoft windows
• Disk Operating System (DOS)
• Linux
• Unix

The choice of operating system will affect how a computer works. It will probably determine the
type of user interface (command line, menu driven or graphical) that the computer uses and the
types of processing (batch, transaction or real-time) that the computer can carry out.

COMMAND LINE INTERFACE:

Command Line Interface (CLI) lets you control your PC by typing commands. In the figure
below is command line interface. There's no mouse or graphical controls like you get in a GUI
such as Windows.

GRAPHICAL USER INTERFACE (GUI):

―A graphical user interface (GUI, pronounced "gooey") is a computer environment that


simplifies the user's interaction with the computer by representing programs, commands, files,

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 40


Introduction to Computers & its applications
and other options as visual elements, such as icons, pull-down menus, buttons, scroll bars,
windows, and dialog boxes.‖
By selecting one of these graphical elements,
through either use of a mouse or a selection from a
menu, the user can initiate different activities,
such as starting a program or printing a document
As define in that figure:

TASKS PERFORMED BY AN OPERATING SYSTEM

There are several tasks which are performed by practically all operating systems, regardless of
the complexity of the computer the operating system is being used on. These tasks include:

1. Managing communications between software and hardware.


2. Allocation of computer memory.
3. Allocation of CPU time.
4. Run and Manage program
5. Managing files
6. Configure Software and Devices
7. Configure Network
8. Coordinating Tasks
9. Performance Management
TYPE OF OPERATING SYSTEM
An operating system is a software component of a computer system that is responsible for
the management of various activities of the computer and the sharing of computer
resources.

Users and application programs access the services offered by the operating systems, by
means of system calls and application programming interfaces. Users interact with
operating systems through Command Line Interfaces (CLIs) or Graphical User Interfaces
known as GUIs as defined above. In short, operating system enables user interaction with
computer systems by acting as an interface between users or application programs and
the computer hardware.

The types of Operating systems are here under:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 41


Introduction to Computers & its applications
1) Single user/personal computer operating system
2) Multiuser/network operating system
3) Embedded operating system

1) SINGLE USER/PERSONAL COMPUTER SOPERATING SYSTEM:

The most basic type of operating system can only carry out one task at a time and can only be
used by one person at a time. More sophisticated multi-tasking and multi-user operating
systems can appear to carry out more than one task and be used by more than one user at the
same time.

It has further types

• DOS
• MAC OS
• Windows

MULTIPLE USER/NETWORK OPERATING SYSTEM:

Multi-user operating systems are used on large mainframe computers. A mainframe computer
system has one very powerful processing unit. Many users will all share this processing unit.
They use terminals (a keyboard and a screen) to access the mainframe computer.

A multi-user operating system lets more than one user work on a mainframe computer at the
same time.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 42


Introduction to Computers & its applications

Operatingsystemsthat are used on computers connected to networks


usually have to carry out some additional tasks. Probably the most important of these is
managing system security. Important aspects of systems security that an operating system might
manage are :

• Controlling who has access to which files.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 43


Introduction to Computers & its applications
• Keeping a log of all of the files that a user changes.
• Automatically backing up important files.

These operating systems are more complicated and require faster hardware and more memory to
work than more basic operating systems.

It has further types

• WINDOWS NT SERVER
• WINDOWS 2000 SERVER
• UNIX

PROGRAMING LANGUAGES
A language in simple word is a way of communication for any person to other person in order to
understand his talk.

Like in the picture above a girl is communicating, the man who is sitting next to her. So the
language is very important medium of communication like linguistics of human. Like human
languages, each programming language has its own grammar and syntax. There are many
components of the same language Computer also need a language so that it can communicate to
the hardware and other important components of computer. Definition:

A language used to write instructions for the computer. That is the way of representation any
program in to that form which is understandable by CPU.

Reminder: program is written instruction for computer.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 44


Introduction to Computers & its applications
Programs are written by using any language and these languages set the procedures & rules to
write computer programs. Programmers have to follow that rules which is set by programming
languages.

TYPES OF PROGRAMMING LANGUAGES


According to structure, interface and procedure computer languages can be divided in to two
major types.

1. Low Level Language


2. High Level Language

LOW LEVEL LANGUAGE


Low level language is also called machine language. That types of languages are close to
machine and easily understand by machine as, it is majorly in binary form (0 & 1).low level
language types are

• Machine language
• Assembly language

MACHINE LANGUAGE

This program written is this type of language sometimes referred to as machine code or object
code, machine language is a collection of binary digits or bits that the computer reads and
interprets. Machine language is the only language a computer is capable of understanding.
Machine code is consisting of 0 & 1. Which mean off and on bit.

Program written in machine language is very fast but machine dependent. It is also referred as
―First Generation Language‖.

Machine code

ASSAMBLY LANGUAGE

Assemble language is also low level language close to machine language. It is also referred as
assembly or ASL, assembly language and ―Second Generation Language‖.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 45


Introduction to Computers & its applications

Assembly
language

Assembly language used to interface with computer hardware. Assembly language uses structured
commands as substitutions for numbers allowing humans to read the code more easily than looking at
binary. Although easier to read than binary, assembly language is still a complex language

HIGH LEVEL LANGUAGE

High level programming languages is languages program than use languages or syntax which
closes to human languages so; it is easy to understanding the languages. This type of language is
machine-independent, and uses similar language as English, which is easily understandable by
human. This type of language’s processing is slow as compared to high level languages. As, it
need any translator between interface on computer and human. So, that both can understand their
languages.

LANUAGE PROCESSOR
As, computer can understand only machine language; that’s why we need an interface between
user and computer so that both can understand its instructions.

Some types of language processors and translator are here under

• Compiler
• Interpreter
• Assembler

COMPILER

A compiler is a computer program that transforms human readable complete code of another
computer program into the machine readable code that a CPU can execute.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 46


Introduction to Computers & its applications
INTERPRETER

An interpreter is a computer program that reads the source code of another computer program
and executes that program.
Because it is interpreted line by line, it is a much slower way of running a program than one that
has been compiled but is easier for learners because the program can be stopped, modified and
rerun without time-consuming compiles.

ASSEMBLER

Assembler converts code written in assembly language into machine language. It works same
like interpreter and compiler.

The assembler program takes each program statement in the code and generates a corresponding
bit stream or pattern (a series of 0's and 1's of a given length).
APPLICATION SOFTWARE
DEFINATION:

―Application software consists of programs designed to perform specific tasks for users‖.

Application software can be used as a productivity/business tool; to assist with graphics and
multimedia projects; to support home, personal, and ed ucational activities; and to facilitate
communications.

Application software divided in to two main types

• Custom based software


• Package software

NETWORK AND INTERNET


COMPUTER NETWORK
DEFINATION:

―A computer network is a group of computers which are connected together to allow


communication between them.‖

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 47


Introduction to Computers & its applications

TYPES OF NETWORK

There are two main types of network :

• LAN
• WAN

LOCAL AREA NETWORK (LAN) :

Definition: “A network which is located entirely


on one site such as an office, school or within a
group of buildings that are in close proximity, that
are connected together.‖

WIDE AREA NETWORK (WAN) :

“A network which connects together computers on


a number of sites in different areas‖.

A WAN or Wide Area Network is a group of


widely dispersed computers that are connected together. These could be across the same town, or
across a country or even across the world‖.
Apart from distance, the other feature that distinguishes as WAN from a LAN is that the WAN
would make use of a range of communication technologies such as telephone, microwave and
satellite links.

Using a WAN, schools in Florida can communicate with places like Tokyo in a matter of
minutes, without paying enormous phone bills. A WAN is complicated.

Metropolitan Area Network (MAN)

 Definition: A network that covers a larger geographical area than a LAN but smaller than a
WAN, such as a city or a large campus.
 Features:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 48


Introduction to Computers & its applications
o Often used by cities to connect municipal offices.
o Example: A network that connects multiple campuses of a university within a city.

d. Personal Area Network (PAN)

 Definition: A small network used for personal devices, usually within a range of a few meters.
 Features:
o Typically involves devices like smartphones, tablets, and laptops.
o Example: Bluetooth connections between a smartphone and wireless earbuds.

ADVANTAGES OF NETWORK

• SPEED.

Networks provide a very rapid method for sharing and transferring files. Without a network, files
are shared by copying them to memory cards or discs, then carrying or sending the discs from
one computer to another. This method of transferring files can be very time-consuming.

• COST.

Networkable versions of many popular software programs are available at considerable savings
when compared to buying individually licensed copies.

• SECURITY.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 49


Introduction to Computers & its applications
Files and programs on a network can be designated as "copy inhibit," so that you do not have to
worry about illegal copying of programs. Also, passwords can be established for specific
directories to restrict access to authorized users.
• CENTRALIZED SOFTWARE MANAGEMENT.

One of the greatest benefits of installing a network at a school is the fact that all of the software
can be loaded on one computer (the file server). This eliminates that need to spend time and
energy installing updates and tracking files on independent computers throughout the building.

• RESOURCE SHARING.

Sharing resources is another advantage of school networks. Most organizations cannot afford
enough laser printers, fax machines, modems, scanners, and CD players for each computer.
However, if these or similar peripherals are added to a network, they can be shared by many
users.

• ELECTRONIC MAIL.

The presence of a network provides the hardware necessary to install an e-mail system. E-mail
aids in personal and professional communication for all personnel, and it facilitates the
dissemination of general information to the entire staff. Electronic mail on a LAN can enable
students to communicate with teachers and peers at their own institute. If the LAN is connected
to the Internet, we can communicate with others throughout the world.

• FLEXIBLE ACCESS.

Networks allow users to access their files from computers throughout the institute. Like Students
can begin an assignment in their classroom, save part of it on a public access area of the network,
then go to the media center after school to finish their work. Students can also work
cooperatively through the network.

• WORKGROUP COMPUTING.

Collaborative software allows many users to work on a document or project concurrently. For
example, educators located at various schools within a county could simultaneously contribute
their ideas about new curriculum standards to the same document, spreadsheets, or website.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 50


Introduction to Computers & its applications

NETWORK TOPOLOGY
Network topology refers to the layout used to wire the computers together.

TYPES OF TOPOLOGY

There are four main topologies that are used.

1. BUS
2. STAR
3. RING

BUS TOPOLOGY

Each computer is connected to a single cable which connects all of the computers. All nodes (file
server, workstations, and peripherals) are connected to the linear cable.

Advantages of Bus Topology


• Easy to connect a computer or peripheral to a linear bus.  Requires less cable length
than a star topology.

Disadvantages of a Bus Topology

• Entire network shuts down if there is a break in the main cable.


• Terminators are required at both ends of the backbone cable.
• Difficult to identify the problem if the entire network shuts down.
• Not meant to be used as a stand-alone solution in a large building.
STAR TOPOLOGY

―All communication takes place via a central computer or HUB device.‖

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 51


Introduction to Computers & its applications

A star topology is designed with each node connected directly to a central network hub, switch,
or concentrator.

Data on a star network passes through the hub, switch before continuing to its destination. The
hub, switch, or concentrator manages and controls all functions of the network. It also acts as a
repeater for the data flow.

Advantages of a Star Topology

• Easy to install and wire.


• No disruptions to the network then connecting or
removing devices.
• Easy to detect faults and to remove parts.

Disadvantages of a Star Topology

• Requires more cable length than a linear topology.


• If the hub or concentrator fails, nodes attached are disabled.
• More expensive than bus topologies because of the cost of the HUB device.

RING TOPOLOGY
Each computer is connected to the two computers on
either side of it. The last computer is linked to the first
to form a ring.

Advantages of a Ring Topology

• Easy to install and wire.


• Equal Access to devices no one computer will
use all the bandwidth
• Easy to detect faults and to remove parts.

Disadvantages of a Ring Topology

• Slow since signals goes in sequential order


• If the concentrator fails, nodes attached are disabled.
• Single break in cable can disrupt the flow of network.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 52


Introduction to Computers & its applications

Network Devices

Devices used in networking enable communication and data flow between connected systems. Key
devices include:

a. Router

 Function: Directs data between different networks, usually between a local network (LAN)
and the internet (WAN).
 Use: Home internet routers connect local devices to the internet.

b. Switch

 Function: Connects multiple devices within a LAN and directs data to the correct device.
 Use: Common in office LANs to manage data flow between computers.

c. Hub

 Function: Similar to a switch, but it broadcasts data to all devices in the network, regardless
of the destination.
 Use: Older, less efficient technology compared to switches.

d. Access Point (AP)

 Function: Extends wireless coverage in a network by allowing wireless devices to connect to


the LAN.
 Use: Common in wireless networks to provide Wi-Fi coverage in large areas.

e. Modem

 Function: Converts digital data from a computer to a signal that can be transmitted over
telephone lines or cable.
 Use: Common in home internet setups to connect the local network to the internet via ISPs.

4. Communication Protocols

Protocols are rules that govern how data is transmitted and received in a network. Common protocols
include:

a. Transmission Control Protocol/Internet Protocol (TCP/IP)

 Function: The fundamental protocol for data communication on the internet, ensuring data is
sent and received correctly.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 53


Introduction to Computers & its applications
 Use: Used in all internet-based communication, from web browsing to file transfers.

b. Hypertext Transfer Protocol (HTTP/HTTPS)

 Function: Governs data exchange between a web browser and a web server.
 Use: HTTP is used for regular websites, while HTTPS (secure) is used for encrypted, secure
connections (e.g., online banking).

c. File Transfer Protocol (FTP)

 Function: Allows the transfer of files between a client and a server.


 Use: Commonly used to upload and download files to/from web servers.

d. Simple Mail Transfer Protocol (SMTP)

 Function: Governs the sending of emails.


 Use: Used by email clients and servers to send and receive messages.

5. IP Addressing

Every device connected to a network is assigned a unique identifier known as an IP address. There
are two main types of IP addresses:

 IPv4: The older version, using 32-bit addresses (e.g., [Link]). Limited to about 4.3
billion unique addresses.
 IPv6: The newer version, using 128-bit addresses to provide more unique addresses (e.g.,
[Link]).

6. Wireless vs Wired Networks

a. Wired Networks

 Description: Devices are connected via physical cables (Ethernet).


 Pros: Faster, more secure, and stable.
 Cons: Limited mobility, requires cabling.

b. Wireless Networks

 Description: Devices connect via radio waves (Wi-Fi).


 Pros: Greater mobility and easier installation.
 Cons: Can be slower and less secure than wired networks.

7. Network Security

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 54


Introduction to Computers & its applications
With the increasing reliance on networks, security has become a critical concern. Common security
measures include:

a. Firewalls

 Function: Monitors and controls incoming and outgoing network traffic based on
predetermined security rules.
 Use: Protects networks from unauthorized access and cyberattacks.

b. Encryption

 Function: Converts data into a secure format that can only be read by authorized parties.
 Use: Ensures the privacy and security of data sent over public networks.

c. Virtual Private Network (VPN)

 Function: Creates a secure, encrypted connection over a less secure network (like the
internet).
 Use: Allows users to securely access a network remotely.

d. Antivirus Software

 Function: Detects and removes malware from computers and networks.


 Use: Protects against viruses, ransomware, and other cyber threats.

8. Network Performance Metrics

Key metrics to evaluate network performance include:

 Bandwidth: The maximum data transfer rate of a network or internet connection, typically
measured in Mbps (megabits per second).
 Latency: The time it takes for data to travel from the source to the destination, measured in
milliseconds (ms).
 Jitter: The variation in time between data packets arriving, which can affect real-time
communications like VoIP.
 Packet Loss: The number of data packets that never reach their destination, affecting the
reliability of the network.

EMAIL

Electronic Mail (email) is a system which allows users of a computer network to send messages
to each other. Users can usually:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 55


Introduction to Computers & its applications

• Send a message to another user, or group of users.


• Keep their messages in a mailbox.
• Read, print and delete messages from their mailbox.

It is not only typewritten messages that can be sent using Electronic Mail. Pictures, music,
videos, in fact almost any sort of information you can think of, can also be sent.

Each user has to have his or her own address that other users need to know to send messages to
him or her.

Electronic mail is good because it is much faster that the ordinary post. It is also very accessible
since you can read your email on any suitable computer anywhere in the world. On the other
hand not everybody has an electronic mailbox at the moment, so you cannot use email to send
messages to everyone, and you certainly can’t send a parcel by email.

There are many email service provider companies which allow any user to send and receive
electronic mail like

• Hotmail o [Link]
• Yahoo o [Link]/mail
• Gmail o [Link]

Operating Systems

 Definition: Software that manages hardware and software resources.


 Functions:
o File Management.
o Process Management.
o Memory Management.
 Types: Windows, Linux, macOS.
 Mobile Operating Systems: Android and iOS, with Android being common in Kenya due to
widespread smartphone use.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 56


Introduction to Computers & its applications

6. Introduction to Databases

 Definition: A structured collection of data stored and accessed electronically.


 Types of Databases:
o Relational Database Management System (RDBMS): Data stored in tables (e.g.,
MySQL, Oracle).
o Non-relational (NoSQL) Databases: Flexible data models (e.g., MongoDB).
 SQL (Structured Query Language): Used to manage and manipulate relational databases.

DATA REPRESENTATION IN A COMPUTER.


Computers handle data by electrical components, e.g. Transistors, Semiconductors, Integrated
Circuits or wires, which exist in two conditions (states), ON & OFF or “1” & “0”.
Inside the computer, data is represented by storage cells, which are either electronically charged
or discharged. Examples;
 In RAM, the cells can be charged and discharged at will, and this can be used to store
different data items. The charged state of the cell can be represented by 1 (or ON), while the
uncharged state by 0 (or OFF).
In ROM, the cells are permanently set to one state.
 A Transistor may be conducting or non-conducting.
 A Magnetic material may be magnetized in one direction or the other.  A wire may or
may not be carrying a current.
The Main memory of the computer can be considered as a collection of thousands of storage
cells, each capable of representing a binary digit.

DATA TYPES.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 57


Introduction to Computers & its applications
Data is a term used to describe a set of facts. A single fact is known as Datum.
Data can be in 3 types or forms.
1. Numeric data (numbers)
2. Alphabetic data.
3. Alphanumeric data.
Numbers:
Numbers can be expressed as either;
 Integers - whole numbers, e.g., 124, -26, or
 Real numbers - numbers with decimal points, e.g., 1.23, -2.6.
Note. A whole number is Real if it is written with a decimal point, e.g., 25 is an integer, but 25.0
is real.

Alphabetic data:
This is data made from combination of alphabetic characters, such as names, title, marital status,
e.g. “John”, “Prof.”, “Married”.

Alphanumeric data (Strings):


A string is any sequence of characters.
This is data made from combination of alphabetic characters, numerals and/or special characters.
Examples;
Names - NG’ANG’A, ANN NDUVA
Address - P.O BOX 299, UGUNJA
Date - November 14, 1990
Account numbers - AO133
Department - Sales department
Messages - Incorrect. Try again
Exercise.
1. Explain the terms Numeric and Alphanumeric. Illustrate your answers with appropriate
examples.
THE BYTE.
The capacity of a computer memory can be measured in terms of Bits (individual memory cells),
Bytes (groups of cells or bits) or Words (arrangement of the bytes).
 A Bit (Binary digit) is the number 0 or 1 in the representation of a value in binary
notation.
 A Byte is a fixed number of adjacent bits that are operated on as a unit.
Usually, a byte is a group of 8 adjacent bits and can store one character, i.e. 1-byte stores 1
character.
The Byte is the most commonly used unit of measuring the capacity of a computer memory.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 58


Introduction to Computers & its applications
 A Word is a group of bits that the computer recognizes and executes (processes) at a
time. To represent characters, the bits are combined together. The group of bits representing
characters can also be described as Location.
In a Character machine, a location has 6 bits that represents a Byte, while the Byte machines has
8 bits making up a byte.
Character machines Byte machines.
6 bits = 1 byte 8 bits = 1 byte
12 bits = 2 bytes (½ Word) 16 bits =2 bytes (½ Word)
24 bits = 4 bytes (1 Word) 32 bits = 4 bytes (1 Word)
The memory capacity can be expressed as 32k, 64k, 256k, etc. The ‘K’ is a constant used to
represent the Kilobyte, which is made up of 1,024 bytes.
Another unit that can be used to measure the memory is Megabyte (MB). MB is used to denote
(stand for / represent / indicate) a million bytes, i.e. 1024 K is equivalent to 1MB. Note. Half of
a byte is described as a NIBBLE. A Nibble can be made up of 3 bits, for Character machines
and 4 bits for the Byte machines.

Exercise.
1. Data in a computer is represented in one major form. Define the term “Data
representation” in a computer system.
2. Define the following terms:
(i). Bit.
(ii). Byte.
(iii). Character. (iv).
Word.
3. Explain the term “NIBBLES” as used in data representation in computers.

CODING OF DATA.
A computer can understand only one language consisting of two symbols, 0 & 1(Binary digits).
Since the computer cannot understand data represented in human languages (i.e. numerals 0 - 9,
alphabets A – Z, and special symbols such as +, -, /, *, etc), it became necessary to change the
data to binary form, a process known as Coding of data.
In other words, to make communication possible between computers and human beings, data
must be coded in the form that can be understood by the computer and the information supplied
by a computer (after processing) must be coded in the form that can be understood by the user.
The coding and decoding of data in a computer is done by the Input/Output devices.
Codes used in Computer systems.
Human readable
Human Computer works -OR-
message Input Code converted to in CPU Code CPU Code converted Machine readable

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 59


Introduction to Computers & its applications

Computer Code by Input devices to Output Code by Code


Output devices
Data representation – The representation of normal data in some type of coded form, such as
BCD, ASCII or EBCDIC.

NUMBER SYSTEMS.
The design and organization of a computer depends on the number system. The 4 number
systems are:-
1. Binary number system (Base 2).
2. Octal number system (Base 8).
3. Decimal number system (Base 10).
4. Hexadecimal number system (Base 16).
Binary numbers are numbers to base 2, and use only two digits; 0 & 1.
Octal numbers, are numbers to base 8, and consists 8 digits (0 to 7).
The decimal number system consists of 10 digits, 0 to 9.
Hexadecimal numbers are numbers to base 16 and there must be 16 digits. The sixteen symbols
used in the Hexadecimal system are; digits 0 to 9 & alphabets A to F.

Number System Base Digits and/or symbols represented


Binary 2 0, 1
Octal 8 0, 1, 2, 3, 4, 5, 6, 7
Decimal 10 0, 1, 2, 3, 4, 5, 6, 7, 8, 9
Hexadecimal 16 0, 1, 2, 3, 4, 5, 6, 7, 8, 9, A, B, C, D, E, F

DECIMAL NUMBER SYSTEM.


The decimal number system consists of 10 digits, 0 to 9.
In decimal system, each digit has; • A Digit value (0 to
9).
• A Positional value, which is determined by how many places to the left or the right of the
decimal point the digit is written.
Note. The Digit value & Positional value for each number system depend on the base of the
number system.
Powers of the base increase as we move to the left and decrease as we move to the right.
Summary for decimal number system (Integers only).
7th 6th 5th 4th 3rd 2nd 1st Position
106 105 104 103 102 10 10 Power base
1 0

1000000 100000 10000 1000 100 10 1 Value

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 60


Introduction to Computers & its applications

Summary for Integers as well as Real numbers.


4th 3rd 2nd 1st 1st 2nd 3rd 4th 5th Position
.
103 102 101 100 10-1 10-2 10-3 10-4 10-5 Power base
.
1000 100 10 1 1/10 1/100 1/1000 1/10000 1/100000 Value
.
Decimal point.
The value of each digit in a number depends on the following:
(i). The digit itself, i.e. the face value of the digit.
(ii). The base of the number system.
(iii). The position of the digit in the number.

Example,
Let us consider the number 8888. All the digits represent the same value of 8. However, the
positional values are the absolute values multiplied by 10 raised to the positional power.
10 10 10 10
3 2 1 0

8 8 8 8
= (8x103) + (8x102) + (8x101) + (8x100)
= (8x1000) + (8x100) + (8x10) + (8x1)
= 8000 + 800 + 80 + 8
= 8888
Since the positional increment is a power of 10, the value 10 is known as the Base of the number
system.
Therefore, the Base of a number system is the value whose positional power is used to represent
another value. Therefore, in the decimal system, the base is 10. Example 1. To represent 5621
in the decimal system, it will be:
10 10 10 10
3 2 1 0

5 6 2 1

= (5x103) + (6x102) + (2x101) + (1x100)


= (5x1000) + (6x100) + (2x10) + (1x1)
= 5000 + 600 + 20 + 1
= 5621
Note. In the Decimal system, the position value of each digit in a number increases 10 times as
we move from right to left starting with the rightmost digit.
Example 2: Fractional numbers.
(i). 0.839

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 61


Introduction to Computers & its applications
10 10- 10- 10-
0 1 2 3

0 · 8 3 9

= (0x100 ) . (8x10-1) + (3x10-2) + (9x10-3) =


(0) . (8x1/101) + (3x1/102) + (9x1/103)
= (0). (8x1/10) + (3x1/100) + (9x1/1000)
= 0.8 + 0.03 + 0.009
= 0.839
(ii). 342.85
10 10 10 10- 10-
2 1 0 1 2

3 4 2 · 8 5

= (3x100) + (4x10) + (2x1) . (8x1/10) + (5x1/100)


= (300 + 40 + 2) + (0.8 + 0.05)
= 342.85

BINARY NUMBER SYSTEM.


Binary is the representation of data by only 2 possible conditions (i.e. combinations of 1 & 0).
Binary system is a number system that uses only two digits; 0 & 1. It has a base of 2, and is
therefore called a Base-two system.
In the binary number system, the digits ‘1’ & ‘0’ are referred to as Bits (binary digits).
Exponential value 25 24 23 22 21 20
Integer value 32 16 8 4 2 0

It is clear that, the positional values of the numbers increase 2 times as we move from right to
left. This is because the base is 2.
Points.
Bit (Binary digit) – The digit 0 or 1 in the representation of a value in Binary notation.
Binary numbers are very important in the design, organization, and understanding of computers.
The Binary system is more convenient because the computer storage systems are based on a 2-
state principle (digits 1 & 0). For example;
(i). Magnetic storage media use the magnetic principles to imitate the states of 1’s & 0’s.
A magnetized spot represents a 1, while the non-magnetized spot represents a 0.
(ii). The computer’s Internal memory uses magnetic polarity in one direction to represent a ‘1’
and in the reverse direction to represent a ‘0’.
(iii). The computer logical operations are also affected by pulse trains, where a pulse represents a
‘1’ and no pulse represent a ‘0’.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 62


Introduction to Computers & its applications
In addition, the Binary code is used only for mathematical applications (it is not intended to
handle alphabetic data).

OCTAL NUMBER SYSTEM.


In Octal number system, there are only 8 possible digits (0 to 7).
Each digit (number) in base 8 has its place value determined by 8.
The position value of a digit increases to the left of the octal point in ascending powers of 8.
For example, 21638 can be expressed as:
8 8 8 8Assign the powers to base 8.
3 2 1 0
Note. Octal number system is more popular with microprocessors,
2 1 6 3
because the number represented in octal system can be used directly for
input and output operations.
Complex binary numbers with several 1’s and 0’s can be conveniently handled in base 8. The
binary digits are combined into groups of 3 (three), and each group is used to represent an
individual octal digit.
HEXADECIMAL NUMBER SYSTEM.
In Hexadecimal number system, the base is 16 and there must be 16 digits.
The sixteen symbols used in the Hexadecimal system are; digits 0 to 9 & alphabets A to F.
The equivalence between hexa-numbers and decimal numbers is as shown below:-
Decimal Hexadecimal.
10 A 11 B
12 C 13 D 14 E
15 F
Each digit in the Hex number system has its place value expressed in terms of 16.
E.g. the value 12A0 can be expressed as:
16 16 16 16 Assign the powers to base 16.
3 2 1 0

1 2 A 0 Note. Hexadecimal numbers are used because more complex


binary notations can be simplified by grouping the binary digits
(bits) into groups of 4’s, each group representing a hexadecimal digit.
E.g. a Binary number such as 10010101000002 can be handled in base 16 as:
21 23 21 Assign the powers to base 2.
20
0 0 0 1 0 0 1 0 10 1 0 0 0 0 0
= (1x20) (1x21) {(1x23)+(1x21)}
0
= 1 2 (8 + 2) 0
= 1 2 10 0
=12A016.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 63


Introduction to Computers & its applications
Note. The Hex system is very well suited for big computers such as IBM and microprocessors
with CPU chips such as INTEL 8085. This is because the Hex number system represents
information in short form.

Exercise I.
1. State the FOUR types of Number systems.
2. Define and explain Decimal notation.
3. (a). What is the Binary system of numbers?
(b). Explain the main features of Binary notation.
(c). State one reason why computers use binary numbers.
4. Write out what A,B,C, and D represent in the table below.
Number System Values
A 0,1
B 0,1,2,3,4,5,6,7
C 0,1,2,3,4,5,6,7,8,9
D 0,1,2,3,4,5,6,7,8,9,A,B,C,D,E,F
A __________________________ B ______________________________ C
__________________________ D ______________________________
5. (a). Explain the main characteristics of Octal notation.
(b). Explain the advantages of using Octal numbers over binary numbers.
6. Write a short note on Hexadecimal notation.

BASE CONVERSIONS.
Human beings normally work with the base 10 notation, i.e. all the data passed to go as computer
input is usually in decimal notation. Subsequently, the results of the computer operations are
communicated to the users in a form they can understand, i.e. in base 10 (decimal) notations.
The Base Conversion is therefore used to help computer users understand how data and
information is communicated between the computer and the user.

(i). FROM DECIMAL TO BINARY.


To convert a Decimal number (base 10) to a Binary number (base 2), the decimal number is
repeatedly divided by 2, until the number cannot be further divided by two. On each division, the
remainder is noted.
Then, the remainders are copied from the bottom Upwards to give the binary equivalent of the
decimal number.
Example 1: Convert a decimal no. such as 12110 to its binary equivalent.
2 121 REM
2 60 1
2 30 0

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 64


Introduction to Computers & its applications
2 15 0
2 7 1 Copy
2 3 1
2 1 1
1 1

12110 11110012
Example 2: Convert the following decimal integers into their binary equivalents. (i). 36
2 36 REM
218 0
29 0
24 1 Copy
22 0
21 0
1 1
12110 1001002
(ii). 247
2 247 REM
2 123 1
2 61 1
2 30 1
2 15 0 Copy
2 7 1
2 3 1
2 1 1
1 1

24710 111101112
Fractional numbers.
For a fractional number, the no. is divided into 2 parts; the whole number part & the fraction
part.
The whole no. is then converted to binary individually as shown above. The fraction part is
repetitively multiplied by 2, noting the complete units of two. This is done until the fraction
becomes a 0 or starts recurring.
The complete units of the fraction part are then copied downwards.
Example 1: Convert a decimal number such as 26.2510 to its binary equivalent.
2 26 REM Fractional part
2 13 0
2 6
2 3 by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 65
Prepared
2 1
1
Introduction to Computers & its applications
1 0.25 x 2 = 0.50 0 Copy 0 Copy 0.50 x 2 = 1.00 1 1 0.00x2 (not
necessary, hence stop) 1
0.25 0.01
2610 110102

Therefore, 26.2510 11010.012

(ii). FROM BINARY TO DECIMAL.


To convert a binary number to decimal system, the number in binary form is assigned weighting
factors (place values) for each digit.
The partial products (i.e. the product of each digit and its corresponding weight) are obtained,
and then added to give a decimal number equivalent of the binary number.
Example 1: Convert the binary number 10110 to decimal.
2 2 2 2
4 3 2 1 0

1 0 1 1 0 2Assign the powers to base 2.


=(1x2 ) + (0x2 ) + (1x22) + (1x21) + (0x20)
4 3

=16 + 0 + 4 + 2 + 0 Therefore,
101102 2210
Explanation:
Note that the binary number 10110 has 5 digits. Starting with the rightmost digit, the Most
Significant Digit (MSD) is in the 5th position. So, it is multiplied by 24 & each digit on its right
will be half of it in its positional value. The products obtained are added together to get the
required decimal equivalent.
Example 2: Convert the binary number 11110012 to its decimal equivalent.
2 2 2 2 2 2
6 5 4 3 2 1 0

1 1 1 1 0 0 1 2Assign the powers to base 2.


= (1x2 ) + (1x2 ) + (1x2 ) + (1x2 ) + (0x22) + (0x21) + (1x20)
6 5 4 3

Sum = 64 + 32 + 16 + 8 + 0+ 0 + 1
= 121
Therefore, 11110012 12110
Example 3: Determine the decimal equivalent of the following binary numbers.
(i). 1011
Solution.
= (1x23) + (0x22) + (1x21) + (1x20)
=8+0+2+1

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 66


Introduction to Computers & its applications
Therefore, 10112 1110
(ii). 11011
= (1x24) + (1x23) + (0x22) + (1x21) + (1x20)
= 16 + 8 + 0 + 2 + 1
Therefore, 110112 2710
(iii). 110101
= (1x25) + (1x24) + (0x23) + (1x22) + (0x21) + (1x20)
= 32 + 16 + 0 + 4 + 0 + 1
Therefore, 110102 5310
(iv). 111000101
= (1x28) + (1x27) + (1x26) + (0x25) + (0x24) + (0x23) + (1x22) + (0x21) + (1x20)
= 256 + 128 + 64 + 0 + 0 + 0 + 4 + 0 + 1
Therefore, 1110001012 45310

Fractional numbers.
For a fractional number, the whole no. is converted to decimal as above.
The digits in the fraction part are divided by multiples of 2, starting from the decimal point.
Example 1: Convert a binary no. such as 11010.012 to its decimal equivalent.
2 2 2 2 2- 2-
4 3 2 1 0 1 2

1 1 0 1 0 . 0 1
2 Weights.
= {(1x24) + (1x23) + (0x22) + (1x21) + (0x20)}. {(0x2-1) + (1x2-2)}
Sum = 16 + 8 + 0 + 2 + 0+ 0 + ¼
= 26 ¼
= 26.25

Therefore, 11010.012 26.2510 Points to Note.


(i). 2-11/21½
(ii). 5-21/521/25
(iii). 20 1 (any no. raised to the power of 0 is 1.)
Example 2: Express the following binary fractions to their decimal equivalents:(i).
(0.111)2

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 67


Introduction to Computers & its applications
2 2- 2- 2-
0 1 2 3

0 . 1 1 1
Weights.
= (0x20). {(1x2-1) + (1x2-2) + (1x2-3)}
Sum = ½ + ¼ + ⅛
= 0.5 + 0.25 + 0.125 Therefore, 0.1112
0.87510
(ii). (11011.101)2
2 2 2 2 2 2- 2- 2-
4 3 2 1 0 1 2 3

1 1 0 1 1 . 1 0 1
. Weights.
= {(1x24) + (1x23) + (0x22) + (1x21) + (1x20)}. {(1x2-1) + (0x2-2) + (1x2-3)}
Sum = 16 + 8 + 0 + 2 + 1+ ½ + 0 + ⅛
= 27 + 0.5 + 0.125
Therefore, 11011.1012 27.62510

(iii). FROM DECIMAL TO OCTAL.


To convert a Decimal number to its octal equivalent, divide the decimal number given repeatedly
by 8 until the quotient obtained is zero.
Example 1: Convert 69110 to Octal.
8 691 REM
8 86 3
8 10 6 Copy
8 1 2
1 1

Therefore, 69210 12638


Example 2: Convert the following decimal numbers to their octal equivalent.
(i). 785
8 785 REM
8 98 1
8 12 2 Copy
8 1 4
1 1
Therefore, 78510 14218
Check (1421)8 = 1x83 + 4x82 + 2x81 + 1x80
= 512 + 256 + 16 + 1

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 68


Introduction to Computers & its applications
= (785)10
(ii). 8159
8 8159 REM
8 1019 7
8 127 3 Copy
8 15 7
8 1 7
1 1
Therefore, 815910 177378
Fractional numbers.
To convert decimal fractions into their equivalent octal fractions, the whole part of the decimal
number is repeatedly divided by 8.
The fractional part is repetitively multiplied by 8, noting the complete units of 8, until the
fractional part becomes zero or up to the required number of digits. The complete units are then
copied downwards.
Example 1: Convert a decimal number such as 98.12510 to its octal equivalent.
8 98 REM Fractional part
8 12 2
8 1 4 Copy 0.125 x 8 = 1.00 1 Copy
1 1 0.00 x 8 (not necessary)
9810 1428 0.12510 0.18

Therefore, 98.12510 142.18


Example 2: Convert the following decimal fractions to their equivalent octal fractions.
(i). 0.75
0.75 x 8 = 6.00
(Since the fractional part has become zero, there is no need to proceed further).
Therefore, 0.7510 0.68

Check (0.6)8 = 6x8-1 = 6x (1/8) = 6x0.125 = (0.75)10


(ii). 0.21875
0.21875 x 8 = 1.75000 1 Copy
0.75000 x 8 = 6.00000 6

Therefore, 0.2187510 0.168

Check (0.16)8 = 1x8-1 + 6x8-2


= 1x(1/8) + 6x(1/64)
= (1x0.125) + (6x0.015625)

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 69


Introduction to Computers & its applications
= 0.125 + 0.093750
= (0.21875)10

(iv). FROM OCTAL TO DECIMAL.


The octal number is assigned the weights in terms of 8’s.
Example 1: Convert 12638 to decimal.
8 8 8
3 2 1 0

1 2 6 3 8Assign the powers to base 8.


= (1x8 ) + (2x8 ) + (6x8 ) + (3x80)
3 2 1

Sum = 512 + 128 + 48 + 3


= 691

Therefore, 12638 69110


Example 2: Convert the following octal numbers to their decimal equivalents.
(i). 41
(41)8 = (4x81) + (1x80) Sum = 32
+1
= 33
Therefore, (41)8 (33)10
(ii). 283
(283)8 = (2x82) + (8x81) + (3x80) Sum =
128 + 64 + 3
= 195
Therefore, (283)8 (195)10
Example 3: Convert 60578 x 428 to decimal.
8 8 8
3 2 1 0

6 0 5 7 8Assign the powers to base 8.


= (6x83) + (0x82) + (5x81) + (7x80)
Sum = 3072 + 0 + 40 + 7
= 311910
8
1 0

4 2 8Assign the powers to base 8.


= (4x8 ) + (2x8 )
1 0

Sum = 32 + 2

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 70


Introduction to Computers & its applications
= 3410

311910 x 3410
9357
12476
106046

Therefore, 60578 x 428 10604610

Fractional numbers.
For a fractional octal number, the whole part is converted to decimal as above. The digits in the
fraction part are divided by multiples of 8.
Example 1: Convert 142.18 to decimal.
8 8 8-
2 1 0 1

1 4 2 . 1 8Assign the powers to base 8


= {(1x82) + (4x81) + (2x80)}. (1x8-1) Sum = 64 + 32 + 2 + 1/8
= 98 1/8
= 98.125
Therefore, 142.18 98.12510
Example 2: Convert the following octal fractions to their decimal equivalents.
(i). (0.54)8
(0.54)8 = (5x8-1) + (4x8-2)
= 5x(1/8) + 4x(1/64)
Sum = 5x 0.125 + 4x0.015625
= 0.625 + 0.062500
= 0.687500
Therefore, (0.54)8 (0.687500)10
(ii). (0.642)8
(0.642)8 = (6x8-1) + (4x8-2) + (2x8-3)
= 6x(1/8) + 4x(1/64) + 2x(1/512)
Sum = 6x 0.125 + 4x0.015625 + 2x0.001953125
= 0.750 + 0.062500 + 0.003906250
= 0.816406250
Therefore, (0.642)8 (0.816406250)10

(v). FROM DECIMAL TO HEXADECIMAL.


The decimal no. is repeatedly divided by 16.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 71


Introduction to Computers & its applications
Example 1: Convert 12210 to its hexadecimal equivalent.
16 122 REM
16 7 A (=10 in decimal)
7 7 Copy Therefore,
12210 7A16
Example 2: Convert decimal number 745 to equivalent hexadecimal number.
16 745 REM
16 46 9
16 2 E (=14 in decimal) Copy
2
2
Therefore, 74510 2E916
Fractional numbers.
For a fractional decimal number, the fraction part is repetitively multiplied by 16, noting the
complete units of 16’s. The complete units are then copied downwards.
Example 1: Convert 32.12510 to hexadecimal.
16 32 REM Fractional part
16 2 0
2 2 Copy 0.125 x 16 = 2.00 2 Copy
0.00 x 16 (not necessary)
3210 2016
0.12510 0.216

Therefore, 32.12510 20.216


(vi). FROM HEXADECIMAL TO DECIMAL.
Assign the hexadecimal number given to the weights in terms of 16’s.
Example 1: Convert 7A16 to decimal.
16 16
1 0

7 A Assign the powers to base 16.


= (7x161) + (Ax160)
Sum = 112 + 10
= 122
Therefore, 7A16 12210
Fractional numbers.
For a fractional hexadecimal value, the whole part is converted to decimal as above. The digits in
the fraction part are divided by multiples of 16.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 72


Introduction to Computers & its applications
Example 1: Convert 20.216 to decimal.
16 16 16-
1 0 1

2 0 . 2
Assign the powers to base 16.
={(2x16 ) + (0x16 )}. (2x16-1)
1 0

Sum =32 + 0 + (2x1/16)


= 32 + 1/8
= 32 1/8
=32.125
Therefore, 20.216 32.12510
Example 2: Convert the following hexadecimal fractions into their decimal equivalents.
(i). (0.8)H
(0.8)H = 8x16-1
= 8x (1/16)
= 0.5000
Therefore, (0.8)H = (0.5000)10
(ii). (A9.328)H
(A9.328)H = {Ax161 + 9x160} + {3x16-1 + 2x16-2 + 8x16-3}
= 10x16 + 9x1 + 3x(1/16) + 2x(1/256) + 8x(1/4096)
= 160 + 9 + 3x 0.0625 + 2x0.00390625 + 8x0.00024414
= 160 + 9 + 0.1875 + 0.0078125 + 0.001953125
= 169.197265625
Therefore, (A9.328)H = (169.197265625)10

(vii).FROM BINARY TO OCTAL.


Example1: Convert the binary number 100011100112 to Octal.
Solution.
The binary digits are grouped into 3’s and each group is used to represent an individual octal
digit.
21 22 21 2 1 20 Assign the powers to base 2. 20
0 1 0 0 0 1 1 1 0 0 1 1
= (1x21) (1x20) {(1x22)+(1x21)} {(1x21)+(1x20)}

= 2 1 (4 + 2) (2 + 1)

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 73


Introduction to Computers & its applications
= 2 1 6 3
= 21638.

(viii). FROM BINARY TO HEXADECIMAL.


Example: Convert the binary number 0110110010001111 to its equivalent hexadecimal number.
Solution.
The binary digits are put into groups of 4’s, each group representing a hexadecimal digit.
22 21 23 22 23 23 22 21 20 Assign the powers to base 2.
0 1 1 0 1 1 0 0 1 0 0 0 1 1 1 1

= {(1x22) + (1x21)} + {(1x23) + (1x22)} + {(1x23)} + {(1x23)+ (1x22) (1x21)+ (1x20)}


= {4 +2} {8+ 4} {8} {8 + 4 + 2 + 1}
=6 12 8 15
= 6C8F16.

The equivalent hexadecimal number is (6C8F)16.

NOTE. You can convert an Octal number to Binary, Hexadecimal to Binary or from Octal to
Hexadecimal.
To do this, first convert the given number to base 10 (decimal), then from base 10 to the required
base.

(ix). FROM OCTAL TO BINARY.


Example1: Convert 3478 to Binary.
Solution.
Step 1: First, convert the given number to base 10 (decimal).
8 8
2 1 0

3 4 7 8Assign the powers to base 8.


= (3x8 ) + (4x8 ) + (7x80)
2 1

= (3x64) + (4x8) + (7x1) = 192


+ 32 + 7 = 23110.
Step 2: Then convert the resulting decimal number to the binary.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 74


Introduction to Computers & its applications
2 231 REM
2 115 1
2 57 1
2 28 1
2 14 0 Copy
2 7 0
2 3 1
2 1 1
1 1

23110 111001112

Therefore, 3478111001112
(x). FROM HEXADECIMAL TO BINARY.
Example 1: Convert 6DC16 to its binary equivalent.
Solution.
Step 1: Convert the hexadecimal (base 16) number given to its decimal (base 10)
equivalent.
6DC
= (6x162)+ (Dx161)+ (Cx160)
= 6x162 + 13x161 + 12x160
= 1536 + 208 + 12 = 175610.
Step 2: Convert the decimal (base 10) number obtained to binary (base 2).
2 1756 REM
2 878 0
2 439 0
2 219 1
2 109 1
2 54 1
2 27 0 Copy
2 13 1
2 6
1
2 3 0
2 1 1
1 1

Therefore, (6DC)16  (11011011100)2


Example 2: Convert A7116 to binary.
Solution.
Step 1: Convert the hexadecimal (base 16) number given to its decimal (base 10) equivalent.
A71

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 75


Introduction to Computers & its applications
= (Ax162)+ (7x161)+ (1x160)
= 10x162 + 7x161 + 1x160
= 2560 + 112 + 1 = 267310.
Step 2: Convert the decimal (base 10) number obtained to binary (base 2).
2 2673 REM
2 1336 1
2 668 0
2 334 0
2 167 0
2 83 1
2 41 1 Copy
2 20 1
2 10 0
2 5 0
2 2
2 1
1
1
0
1

Therefore, (A71)16  (101001110001)2


(xi). FROM OCTAL TO HEXADECIMAL.
Example1: Convert 60578 to Hexadecimal.
Solution.
Step 1: First, convert the given octal number to decimal (base 10).
8 8 8
3 2 1 0

6 0 5 7 8Assign the powers to base 8.


= (6x83) + (0x82) + (5x81) + (7x80)
Sum = 3072 + 0 + 40 + 7
= 3119
Therefore, 60578 311910
Step 2: Then convert the resulting decimal number to the Hexadecimal.
16 3119 REM
16 194 F (=15 in decimal)
12 2 Copy
12 C (=12 in decimal)

311910 C2F16

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 76


Introduction to Computers & its applications

Therefore, 60578C2F16 Exercise I.


1. (A). What are Base Conversions?
(B). Explain the following conversions:
(i). From decimal to binary.
(ii). From binary to decimal.
(iii). From decimal to Octal.
(iv). From octal to decimal.
(v). From decimal to
hexadecimal.
(vi). From hexadecimal to
decimal.
2. Perform the following computer arithmetic. In each case, show how you arrive at
your answer.
(A). Convert the following decimal numbers to their binary equivalent.
(i). 11
(ii). 001
(iii). 255
(iv). 2346
(v). 322.6875 (3 marks).
(B). Convert the following binary numbers to decimal.
(i). 110111001 (2 marks)
(ii). 10101.1011 (2 marks)
(C). Convert the following binary numbers to hexadecimal number systems.
(i). 1011 (2 marks).
(ii). 11110101 (2 marks).
(iii). 10100000001111111
(iv). 110111.11 (2 marks).
(v). 1.1110101 (2 marks).
(vi). 0.10111010110011101111

(D).
Convert the following octal numbers to binary.
(i). 77
(ii). 0000001
(iii). 347
(iv). 1263
(v). 473.4 (2 marks).
(vi). 0.354672341
(E). Convert the following hexadecimal numbers to binary.
(i). 13
(ii). C3

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 77


Introduction to Computers & its applications
(iii). 347.2
(iv). BCD
(v). A71
(vi). A71.A
(vii). 0.8746532
(viii).0.7BCEFAD
(F). Convert the following hexadecimal numbers to decimal.
(i). EI.F (2 marks).
(G). Convert the following hexadecimal numbers to octal.
(i). F8
(ii). FBE.E1AB (4 marks).
(H). Convert the following decimal numbers to hexadecimal.
(i). 32.125
(ii). 5.125 (2 marks).
(I). Convert the following binary numbers to octal.
(i). 0.00101110010111
(ii). 0.101110011111010001

Exercise II.
1. Convert the following to Hexadecimal.
(i). 24010 (2 marks).
(ii). 60578 (4 marks).
2. (A). Convert the following numbers to their Binary equivalents.
(i). 3768. (3 marks).
(ii). A6B16. (4 marks)
(B).Convert the following into binary:
(i). 3478.
(ii). 47310.
(iii). BCD16. (12 marks).
3. A. Convert the following numbers into their decimal equivalent showing all steps. (i).
110101.01102
(ii). 3478
B. Convert the following numbers into their hexadecimal equivalent showing all steps
(i). 35610
(ii). 67548
4. Convert the following octal numbers to hexadecimal. (i). 6057
(ii). 56752 (3 marks).
NEGATIVE NUMBERS.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 78


Introduction to Computers & its applications
Both positive and negative numbers can be represented in the computer memory during
processing.
The input numbers whether positive or negative are all represented in binary form.
The negative numbers are used to carry out subtraction in the computer’s arithmetic operations.
This is based on the fact that, subtracting a number is the same as adding its negative to the other.

The following are the various methods used to represent negative numbers in the computer:-
(i). One’s Complement (1C) method.
(ii). Two’s Complement (2C) method.
(iii). Signed Magnitude method.

One’s Complement (1C) method.


In 1C method, the binary digits representing the negative number are negated, (i.e., the 1’s in the
number are changed to 0’s, and the 0’s are changed to 1’s).
E.g., -1710 can be represented in binary as a negative value as:
Step 1: Convert -1710 to binary (base 2).
2 17 REM
2 8 1
2 4 0 Copy
2 2 0
2 1 0
1 1

1710 100012
Therefore, -1710 1 0 0 0 12
Complementing each bit
0 1 1 1 02
-1710 011102 (1C method).

Two’s Complement (2C) method.


In 2C method, the negative number is represented into binary form, then complemented as in 1C
method, but a ‘1’ is added to the Least Significant Digit (LSD) of the complement value. E.g., -
1710 can be represented as: 1710 100012
Therefore, -1710 1 0 0 0 12
Complement each bit, add a ‘1’ to the compliment.
0 1 11 0
1 +
0 1 1 1 1
-1710 011112 (2C method).

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 79


Introduction to Computers & its applications

Signed Magnitude method.


In Signed Magnitude method, the number is divided into two parts; the Sign part and the Data
part.
Usually, a ‘1’ is used to represent a negative sign and a ‘0’ to represent a positive sign. The
Magnitude part is expressed in binary but not complimented. Therefore, one part of the
binary digits will be representing the data value, while the other will represent the sign bit.
To make it simple, it is assumed that the sign bit is 1, while the data bits are equivalent to the
binary number digits representing 17.
E.g., -1710 can be represented in binary as 100012:
1710 100012 (unsigned) Therefore, -1710 1
100012
Sign bit Data bits

+1710  0 100012 Exercise.


1. (a). What are Negative numbers?
(b). Explain the main methods of using negative numbers.

BINARY ARITHMETICS.
ADDITION:
Adding binary numbers is the same as adding decimal numbers. The difference is that, any
complete units of two’s are carried and added to the next significant digit.
Binary addition rules.
During binary addition (i.e. when adding two digits) the following rules need to be noted.
Sum Carry
0 + 0 = 0 0
0 + 1 = 1 0
1 + 0 = 1 0
1 + 1 = 0 1
Example 1:
1 0 0 1
+ 0 1 0 1

1 1 1 0

Example 2:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 80


Introduction to Computers & its applications
1 1 0 1 02
+ 1 0 1 02

1 0 0 1 0 02
Explanation:
Addition of two binary numbers starts from the Least Significant Digits.
 Zero (0) is added to 0 to get a sum of 0.
 The next significant digits, 1 and 1 are added to get a sum of 0 plus a carryout of 1. The
Carryout is given by any complete units of two got after the digits of the same significance
are added.
The carryout from the previous addition becomes the Carry in of the next significant digits, to
which the carry is added.
The procedure continues until the overall sum of the two binary numbers is got.
Note. During arithmetic operations, the data to be worked upon are usually held on locations
(cells) of predefined length or capacity. If the results cannot fit in any of the spaces that contain
the values to be executed, then there is usually an excess bit in the answer.
For instance, in the above example, we have added a 5-bit and a 4-bit number, to get a 6-bit
answer, which cannot fit on either 5-bit or 4-bit areas, hence there is an excess bit in the answer,
what is described as the Arithmetic overflow.
The excess/extra bits of the sum that cannot fit the expected space are known as Overflow.

SUBTRACTION:
Binary subtraction rules.
When subtracting two numbers (i.e. when getting the difference between two numbers), the
following rules must be observed.
Difference Borrowed
(from the next significant digit)
0 - 0 = 0 0
1 - 0 = 1 0
0 - 1 = 1 1
1 - 1 = 0 0
Example 1:
1 1 1 0 12
- 1 0 1 02

1 0 0 1 12
NB. The one (1) you have borrowed is equivalent to 2.
Explanation:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 81


Introduction to Computers & its applications
The subtraction starts with the least significant digits towards the most significant digits.
 In the first subtraction, a 0 is subtracted from a 1, and the difference is a ‘1’.
 In the 2nd subtraction, 1 cannot be subtracted from a 0, and hence a 1 containing 2 is
borrowed from the next significant digit from which a 1 is subtracted and a difference of 1 is
got.
Note that, borrowing 1 from 1 leaves a 0 in the 3rd digit of the number being subtracted from. The
procedures proceed until the subtraction is complete.
Example 2:
11110011 – 1100000 (base 2).
11110011
1100000 -
10010011 (base 2)
Note. Subtraction of binary numbers can also be carried out using the Compliments and Signed
magnitude methods.
Subtraction of binary numbers using the One’s Compliment method.
(11101)2 – (1010)2 Solution.
Step 1: Make the digits of the values the same.
1 1 1 0 1
- 0 1 0 1 0

Step 2: Compliment the digits of the negative number, and then add.
1 1 1 0 1
+1 0 1 0 1

11 0 0 1 0

Overflow
Step 3: Add the overflow digit to the Least Significant Digit of the sum to get the difference.
1 1 1 0 1
+1 0 1 0 1

1 0 0 1 0
1+

1 0 0 1 1 Difference

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 82


Introduction to Computers & its applications
MULTIPLICATION:
When two numbers are multiplied, the output is the Product.
Binary multiplication rules.
The following rules must be used when carrying out a multiplication procedure.
Product
0 x 0 = 0
0 x 1 = 0
1 x 0 = 0
1 x 1 = 1
Example 1:
1 0 1 0 Multiplicand x
1 0 1 Multiplier

1 0 1 0
0 0 0 0 partial products
1 0 1 0

1 1 0 0 1 02 Product

Explanation:
The multiplicand is multiplied by the multiplier digits starting from the Most Significant Digit
towards the least significant digit, shifting one place to the right each time the next multiplier
digit is used to produce the partial product.
The partial products are then added up to give the product of the multiplication.

Example 2:
(i). 11100 x 10010 (base 2).
11100
10010 x
11100
00000
00000
11100
00000
111111000 (base 2)

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 83


Introduction to Computers & its applications
DIVISION:
Computers carry out binary division by repetitive subtraction.
Example 1:
11102 REM 1002
101 1001010
-101
1000
-101
0111
-101
0100

Explanation:
Since the divisor is made up of 3 digits, we start by grouping the dividend bits into groups of 3’s
from the Most Significant Digit.
 In the first grouping, 100 is got, which cannot be divided by 101, and hence extend to 4 digits
and 101 goes into 1001 once. The 1 is copied on top.
The remainder 100 cannot divide into 101, and hence the next digit 0 is added to it forming 1000,
that divides into 101 once, and 1 is copied on top.
The procedure repeats until all the digits of the dividend are exhausted and a remainder of 1110 2
is got.
Example 2:
110

11110
101
101
101
101
00
110
Question.
Perform the following computations:
(i). 11100 x 10010 (base 2).
(ii). 2567 + 3476 (base 8).
2567
3476 +
6265 (base 8)
(iii). 11110011 – 1100000 (base 2). Exercise
I.
1. Explain the following processes of binary arithmetic:
(i). Addition.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 84


Introduction to Computers & its applications
(ii). Subtraction.
(iii). Multiplication. (iv).
Division.
2. Use One’s compliment to solve the following sums:
(i). 9-6 (ii). 17-15
3. Use Two’s compliment to solve the following sums (the numbers are in decimal notation).
(a).13-10. (b). 23-20
(c). 17-14
4. Carry out the following arithmetic:
(i). 1101112 Multiply by 11012
(ii). 60578 multiply by 428 (3 marks).
(iii). 2.48 multiply by 7.68 (3 marks). (iv). 1101102 divide by 1112 (3 marks).
5. Use binary addition to solve the following decimal summations.
(i). 4+3
(ii). 13+2
6. Perform the following binary additions. Your answers should be in the binary format:
(i). 1010 + 0010
(ii). 1111 + 0001 Exercise II.
1. Perform the following binary arithmetic:
(A). (i). 10111 multiply by 1001
(ii). 1011.1 multiply by 1.01 (3 marks)
(B). (i). 1110011 divide by 101
(ii). 11100.11 divide by 1.01 (C). (3 marks)
(i). 1110.0111 add
1101001.0110
(ii). 11101101 add 0101110 (2 marks)
(D). 1001011.011 subtract 111.111 (2 marks).
2. Perform the following hexadecimal arithmetic:
(a). 31 – 9.7 FD (3 marks).
(b). ABCD + 145 (3 marks).
(c). DFAC – 101B (2 marks).
(d). 14.79 + BC.78 + DE.78 (2 marks).
3. Perform the following octal arithmetic:
(i). 2.456 + 17.456 + 31.76 (2 marks).
(ii). 57724.33 add 422.76 (2 marks).

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 85


Introduction to Computers & its applications
(iii). 20 multiply by 13 (2 marks).
(iv). 243.4 multiply by 123 (3
marks).
(v). 421 x 4.7 (3
marks).
(vi). 124 divide by 10 (2
marks).
(vii). 260032 divided by 246 (3
marks).
(viii).21.256 – 6.347 (2
marks).
(ix). 6625.24 subtract 751.76 (2
marks).
COMPUTATIONAL ERRORS.
The main computation errors are:
1). Overflow:
Overflow occurs whenever the results of an arithmetic operation are bigger than the assigned
work area.
E.g. If the result is to be stored in an 8-bit work area (register) and the results generate more than
8 bits, an error message is generated by the computer. This may terminate the normal execution
cycle.
2). Truncation:
To truncate a number is to drop out some digits of the number after the decimal point when for
example a division or fraction gives a recurring quotient.
E.g. Division of 1/9 produces 0.1111…
The quotient, therefore, may be rounded down to 3 decimal places, thereby dropping out the rest
of the values.
I.e. 1/9 = 0.111
3). Rounding Up.
If a division produces a recurring quotient or in fractions that recur, the result (quotient) can be
rounded to the nearest value. E.g., 23/48 = 0.4791666………
In this case, the quotient can be rounded up to 4 decimal places as 0.4792, because the next value
after the 4th decimal place is >=5. However, if it was less that 5, then it would have been rounded
down to 0.4791.
The rounding of numbers (answers/quotients) reduces truncation errors.

4). Floating Point Numbers.


The floating point notation is the expression of a number or values into their standard form
equivalent.
E.g., 1234 can be expressed in standard (floating point) notations as:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 86


Introduction to Computers & its applications
1.234 x 103
Where; 1.234 is the Argument.
10 is the Base.
3 is the Exponent.
Calculations done in floating point notations or any numbers represented in their floating notation
are prone to truncation errors. For example, to represent a number such as 0.1234 x 104 into a 3-
digit accuracy, then the result is truncated.
However, computers with larger storage areas for floating point numbers are less prone to such
truncation errors.
Exercise.
1. Name and explain the four types of computation errors. (20 marks).

COMPUTER CODING SYSTEMS.


The decimal number system is the accepted international system. However, computers can
understand and work only using the binary language, i.e., in 0’s & 1’s.
Therefore, in order to talk to computers, one has to convert the information (whether numeric or
non-numeric) into binary form. The process of representing numeric or non-numeric information
in terms of binary digits is known as Coding.
By using different bit patterns, the non-numeric information, such as letters of the English
alphabet A-Z can be represented.
E.g., letter A is represented as: 110001, while the equal (=) sign is represented as 001011.
In addition, the Digital computers that are frequently used in many business environments use
binary digits to operate, i.e., they accept data & instructions in terms of 1’s and 0’s, work upon
them and produce information, which is immediately stored in the form of 0’s & 1’s before they
are communicated to the end users.
This means that coding in computers is done to achieve the following objectives:
1). To convert numeric & alphanumeric information into binary digits of 0 & 1.
2). To transmit correct data to the computer.
3). To detect and correct errors, if any, during the transmission of data.
The following are the various methods of representing data in Binary Number systems in a
computer:
1. BCD (Binary Coded Decimal).
2. EBCDIC (Extended Binary Coded Decimal Interchange Code).
3. ASCII (American Standard Code for Information Interchange) Code.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 87


Introduction to Computers & its applications
What is a Code?
 A set of rules, outlining the way in which data may be represented.
 Rules used to convert data from one representation to another, e.g. from ASCII to
EBCDIC.

BCD Code.
BCD stands for Binary Coded Decimal.
Usually, there are 2 types of BCD coding;
 4-bit BCD Coding.
 Extended BCD Code.
(1). 4-bit BCD Coding.
This method uses 4 binary digits to represent an individual decimal digit.
Example;
398(10)

0011 1001 1000


A group of 4 bits (binary digits) usually representing a number is known as a NIBBLE.
Decimal BCD Pure Binary
39810 001110011000 1100011102
Note. The BCD notation of the number 39810 is not the same as when represented in the pure
binary notation.
The BCD notation uses more bits than the pure binary notation, and is arithmetically slower.
However, the BCD operations are simple, they remove rounding (truncation) errors & are used to
store data in packed mode.
(2). Extended BCD Code.
This is a 6-bit coding system. It consists of 4 data/numeric bits, and 2 additional bits known as
the Zone bits. An extra bit known as the Parity bit is added (7 bits, when the parity bit is
included).
The Zone bits indicate the type of characters represented by the code, while the Data bits
represent the particular characters represented by the codes.
Numerals, alphabets and special characters can be represented in their binary form using the
Extended BCD coding system. The characters are classified into zones, which are then assigned
zone bits.
Example 1: Zoning of the characters A – Z.
Zone Characters Zone bits
1 A – I 11
2 J – R 10
3 S – Z 01

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 88


Introduction to Computers & its applications
Counting starts from the 1st character within a zone and ends at the last character within that zone.
Note. The Zone bits, in computer with numeric bits, form codes to present characters.
Example 2: The Numeric equivalents of the characters within the zone A – I.
Zone A – I characters Numeric value Binary
A 1 0001
B 2 0010
C 3 0011
D 4 0100
. . .
. . .
. . .
I 9 1001
Similarly, the other numeric values of the characters in the other zones can be determined, i.e.,
J=1 to R=9 and S=2 to Z=9.
The Extended BCD uses unique combinations of two zero bits and 4 numeric bits to represent
specific data characters.
To represent a given character in Extended Binary code, the zone bits are added to the data bits
(the binary digits representing the numerical equivalent to the character), and an extra bit (the
parity bit) added.
To represent a character like A in Extended BCD code:
The zone bits for A are ‘11’ and data bits of A are ‘0001’.
X 11 0001

Parity bit Zone bits Data bits


The Parity bit ‘x’ depends on the machine/computer in use, i.e., whether Even or Odd parity
machine.
For an Even parity machine, the no. of 1’s in a code representing a character adds up to an even
number, while for an Odd parity machine, the no. of 1’s in a code representing a character adds
up to an odd number.
Therefore, the value of ‘x’ is ‘1’ for an even parity machine and ‘0’ for an odd parity machine.
Note that, if X=1, then the no. of 1’s in the code for A are 4, which is an even number. If X=0,
then the number of 1’s remain 3, which is an odd no.
Parity bit – A check bit appended to a collection/group of binary digits to make the sum of all
the binary digits, including the check bit, always odd or always even.
The Parity bit does not change the value of the character stored, but it is used to automatically
detect transmission errors during data communication, e.g., from an external storage media like
cassette to the internal memory. If some bits fall off, the computer responds with a parity failure
error message.
Parity Check – A check to determine whether the number of bits in a pattern is either even or
odd.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 89


Introduction to Computers & its applications
TYPICAL CODING SYSTEM FOR STANDARD BCD CODE.
0 - 000000 A - 010000 L - 100010 W - 110100
1 - 000001 B - 010001 M - 100100 X - 110101
2 - 000010 C - 010010 N - 100101 Y - 110110
3 - 000011 D - 010011 O - 100110 Z - 110111
4 - 000100 E - 010100 P - 100110
5 - 000101 F - 010101 Q - 100111 6 - 000110 G - 010110 R -
101000
7 - 000111 H - 010111 S - 110000
8 - 001000 I - 011000 T - 110001
9 - 001001 J - 100000 U - 110010
K - 100001 V - 110011 ASCII Code.
ASCII stands for American Standard Code for Information Interchange.
This is a standard 7-bit coding system, with 3-zone bits added to the 4-data bits, and an extra
parity bit (8 bits when the parity bit is included).
ASCII code is used for data interchange involving computers and communications equipment.
The ASCII code format for a given character therefore looks like:
x

Parity bit Zone bits Data bits


E.g., letter A can be expressed as; X1011001.
Note. The ASCII coding system can represent up to 128 characters, i.e., 27 characters.

EBCDIC Code.
EBCDIC stands for Extended Binary Coded Decimal Interchange Code.
This is an 8-bit coding system, with 4 zone bits, 4 data bits and an extra parity bit (in total it
consists of 9 bits, when the parity bit is included).
The EBCDIC coding system is an extension of the 6-bit BCD coding system. It allows for the
representation of more characters, i.e., 256 (28 ) characters as compared to the 64 (26) characters
that can be represented in the 6-bit BCD coding system.
The EBCDIC uses unique combinations of 4 zone bits & 4 numeric bits to represent specific data
characters.
The EBCDIC code format for a given character would look like:
x

Parity bit Zone bits Data bits

Exercise I.
Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 90
Introduction to Computers & its applications
1. (a). What is computer coding systems? (5 marks). (b). Name and briefly explain
TWO computer coding systems. (4 marks). (c). State advantages of using Extended BCD
code over 4-bit BCD code. (6 marks).
(d). Explain the purpose of zone bits, and parity bit in a computer coding system. (4 marks).

Exercise II.
1. (a). What is meant by the term Character codes? Give examples.
(b). Explain the principal characteristics of the following by the help of suitable examples: (i).
4-bit BCD code.
(ii). Parity bit.
(iii). ASCII code.
(iv). EBCDIC code.

Exercise III.
1. State THREE methods of representing data in Binary number system.

STORAGE ORGANISATION.
The computer memory is designed in such a way that the basic unit of the stored entities, i.e.,
data, instructions and information, is a 2-state unit representing a ‘1’ or ‘0’. The 2-state quantity
is described as a Bit, Cell or Binary digit. In other words, storage is only possible in terms of
0’s & 1’s.
The two units can be described by electric circuit using two voltages. When there is voltage
(when the circuit is on), a ‘1’ is represented, and when there is no voltage in the circuit (when it is
off), a ‘0’ is represented.
To represent characters the bits are combined together. The group of bits representing characters
can also be described as Location. This location forms the basis of computer storage
organization.
Each individual location has got its unique address (identifier). During storage, the address is
used to determine the location onto which the character is stored and from which subsequently it
is retrieved.
Note. Reading/retrieving characters leaves the contents in a location undestroyed, i.e. reading is
just copying the contents of a location, leaving the copied contents in their location.
On the other hand, Writing to a particular location is destructive in that the previous contents of
that location are replaced with the information being written, i.e. The location contents are
overwritten, hence cannot be recovered.
The no. of bits that defines the location is influenced by the computer design & the instructions
used.
E.g., most microcomputers were originally designed based on the 8-bit organization. However,
due to technological development, modern microcomputers are mostly 16-bit machines.
There are various forms of storage organization.
(i). Character machines & Impacked Binary Fields:

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 91


Introduction to Computers & its applications
Character machines can also be described as Character addressable machines.
In Character machines, each location is made from a group of 6 bits, i.e. the characters are
stored in terms of 6 bits. Each character has its own location and hence a unique address
for reading or writing individual character.
Character machines use the 6-bit BCD coding system in representing character in the
memory.
In Character machines, both characters and numerals are stored in locations of 6 bits. This
means that, if the characters are mostly numeric, then a lot of space is wasted because for
a numeric character, only 4 bits are necessary to represent the data bits, while the zone bits
are just filled in by zeros. This mode of storage location is described as Impacked binary
field (or Impacked storage mode).
(ii). Word machines.
The Word machines use fixed word length storage. The typical word lengths are 24 bits
or 32 bits depending on the computer design.
The Word machines are designed such that, each word has its own unique location, with a
unique address/identifier, which is used to identify the location during writing or reading.
One word can store 4 characters.
Word machines have an advantage in the organization of the entities in the computer
memory in that, the exact number of characters can be stored and retrieved conveniently,
unlike Character machines whose organization of the locations is limited to 6 bits.
(iii). Byte Machines & Packed Binary Fields:
A Byte is made up of 8 bits and can store one character.
The Byte machines are also refereed to as Byte addressable machines.
Byte machines use the EBCDIC coding system (the coding system that uses 8 bits to
represent characters).
The Byte machines have an advantage over the Character machines in that, if the
characters are mostly numeric, they can be stored in packed mode, giving the packed
binary fields. In this mode of storage, two characters are stored in single byte, as opposed
to impacked fields in Character machines, which stores one character per byte.
For example, 2468 can be packed into 2 bytes (16 bits) as compared to Character
machines, which would use 4 bytes (32 bits).
Fig 1: Byte representation of 2468 (packed).
2 4 6 8
0 0 1 0 0 1 0 0 0 1 1 0 1 0 0 0
1 byte 1 byte

2 bytes
Fig 2: Character machine representation of 2468 (packed).
2 4 6 8

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 92


Introduction to Computers & its applications

0 0 0 0 1 0 0 0 0 1 0 0 0 0 0 1 1 0 0 0 1 0 0 0
1 byte 1 byte 1 byte 1 byte

4 bytes
The arrangement of the locations of a Byte machine provides for a unique identifier for each byte,
which can be used for write and retrieval operations on these locations.
The Byte machines can also be described as Variable Word length machines. This is because,
several bytes can be grouped to form words of required length.
The Byte machines are more advantageous for they combine both the capabilities of the
Character and the Word addressable machines.

Exercise I.
1. Expand the following abbreviations:
(a). BIT. (1 mark)
(b). BCD. (1 mark)
(c). ASCII. (1 mark)
(d). EBCDIC. (1 mark)
2. Explain the concept of storage organization.
3. Define/Explain the following terms:
(i). Word machine.
(ii). EPROM.
(iii). Byte machine.
(iv). Character machine.
(v). Packed binary field.
(vi). Impacked binary field. (20
marks).
4. Write short notes on:
(i). Character machines and impacked binary fields.
(ii). Word machines.

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 93


Introduction to Computers & its applications
Introduction to operating systems

 Functions of an operating system (OS).


 Types of operating systems (Windows, Linux, Mac OS).
 File management, memory management, and process management.

 User interfaces (Graphical User Interface, Command-Line Interface).

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 94


Introduction to Computers & its applications

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 95


Introduction to Computers & its applications

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 96


Introduction to Computers & its applications

INTRODUCTION TO DATABASE

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 97


Introduction to Computers & its applications

Prepared by Fazal Mabood [Lecturer Computer Science][03015540084][[Link]] Page 98

You might also like