0% found this document useful (0 votes)
13 views

What Is Computer!

Short intro for beginners. Learn what is Computer
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
13 views

What Is Computer!

Short intro for beginners. Learn what is Computer
Copyright
© © All Rights Reserved
Available Formats
Download as PPTX, PDF, TXT or read online on Scribd
You are on page 1/ 40

Introduction to Computer

Science
Lecture 1
Topics covered in the lecture
What is Computer?
Benefits and Social Repercussions
Major Components of Computer
Hardware
• Input devices
• Processing Devices
• Storage
• Output devices
• Communication devices

Software
• System Software
• Application Software

Hardware components of Computer System


Types of Computers
• Analogue
• Digital
• Super computer
• Mainframe computer
• Mini computer
• Micro computer
• Hybrid
What is a Computer?
• An electronic device that is programmed to
accept data, process data into useful
information and store it for later use
Advantages Disadvantages

Speed Consistency Privacy Public Safety

Impact on
Reliability Storage Health Risks
Labor

Communication
Impact on
Environment
Major Components
• Hardware • Software

The physical, touchable, Software is a set of


electronic and mechanical instructions that tells a
parts of a computer computer what to do
system.
Five main categories of hardware components in a
computer system:
• Input
• Processing
• Storage
• Output
• Communication devices.
HARDWARE COMPONENTS
Input Devices
The devices that are used to enter data and
instructions into the computers
CPU (Central Processing Unit)
The processor is the main “brain” or “heart” of a computer system. It performs all
of the instructions and calculations that are needed and manages the flow of
information through a computer.
Primary storage
(Internal storage, Main Memory or memory) is the computer's working storage
space that holds data, instructions for processing and processed data
(information) waiting to be sent to secondary storage. Physically, primary
storage is a collection of RAM chips.

Types of Memory
ROM – (Read Only Memory) ROM is nonvolatile, meaning it holds
data even when the power is ON or OFF.
Types:
1. MROM (Mask ROM)
2. PROM (Programmable ROM)
3. EPROM (Erasable Programmable ROM)
4. EEPROM (Electrically Erasable Programmable ROM)
Types of RAM
RAM – (Random Access Memory) RAM is volatile, meaning it holds data
only when the power is on. When the power is off, RAM's
contents are lost.
1. Static RAM (SRAM)
2. Dynamic RAM (DRAM)
Secondary Storage
Currently, there are two common types of hard drive:
1. Hard Disk Drive (HDD)
2. Solid State Drive (SSD)

INTERFACES – the connecting part between the computer and the hard drive.

Types of interfaces hard drive have

1. Parallel Advanced Technology Attachment (PATA)


2. Serial ATA (SATA)
3. Small Computer System Interface (SCSI)
4. NVMe (Non-volatile Memory Express)
Output Devices
Output devices are used to display processed
data to the user
HARDWARE COMPONENTS OF A
COMPUTER SYSTEM
System Unit
The main part of a microcomputer, sometimes called the chassis.
It includes the following parts:
• Motherboard
• Microprocessor
• Memory Chips
• Buses
• Ports
• Expansion Slots
• Cards
SOFTWARE COMPONENTS
TYPES OF COMPUTER
Algorithms
Terminology
• Algorithm: A set of steps that defines how a
task is performed
• Program: A representation of an algorithm
• Programming: The process of developing a
program
• Software: Programs and algorithms
• Hardware: Equipment

0-22
History of Algorithms
• The study of algorithms was originally a
subject in mathematics.
• Early examples of algorithms
– Euclidean Algorithm

0-23
The Euclidean algorithm

0-24
Computer Science
• The science of algorithms
• Draws from other subjects, including
– Mathematics
– Engineering
– Psychology
– Business Administration

0-25
Central Questions of Computer Science
• Which problems can be solved by algorithmic
processes?
• How can algorithm discovery be made easier?
• How can techniques of representing and
communicating algorithms be improved?
• How can characteristics of different algorithms
be analyzed and compared?

0-26
Central Questions of Computer Science
(continued)
• How can algorithms be used to manipulate
information?
• How can algorithms be applied to produce
intelligent behavior?
• How does the application of algorithms affect
society?

0-27
The central role of algorithms in computer
science

0-28
Definition of Algorithm
An algorithm is an ordered set of
unambiguous, executable steps that
define a terminating process.

5-29
Algorithm Representation
• Requires well-defined primitives
• A collection of primitives constitutes a
programming language.

5-30
Folding a bird from a square piece of paper

5-31
Origami primitives

5-32
Polya’s Problem Solving Steps
• 1. Understand the problem.
• 2. Devise a plan for solving the problem.
• 3. Carry out the plan.
• 4. Evaluate the solution for accuracy and its
potential as a tool for solving other problems.

5-33
Polya’s Steps in the Context of
Program Development
• 1. Understand the problem.
• 2. Get an idea of how an algorithmic function
might solve the problem.
• 3. Formulate the algorithm and represent it as
a program.
• 4. Evaluate the solution for accuracy and its
potential as a tool for solving other problems.

5-34
Getting a Foot in the Door
• Try working the problem backwards
• Solve an easier related problem
– Relax some of the problem constraints
– Solve pieces of the problem first (bottom up
methodology)
• Stepwise refinement: Divide the problem into smaller
problems (top-down methodology)

5-35
Ages of Children Problem
• Person A is charged with the task of determining the
ages of B’s three children.
– B tells A that the product of the children’s ages is 36.
– A replies that another clue is required.
– B tells A the sum of the children’s ages.
– A replies that another clue is needed.
– B tells A that the oldest child plays the piano.
– A tells B the ages of the three children.
• How old are the three children?

5-36
Figure 5.5

5-37
An algorithm must possess following characteristics :

1. Finiteness: An algorithm should have finite number of


steps and it should end after a finite time.
2. Input: An algorithm may have many inputs or no inputs at
all.
3. Output: It should result at least one output.
4. Definiteness: Each step must be clear, well-defined and
precise. There should be no any ambiguity.
5. Effectiveness: Each step must be simple and should take
a finite amount of time.
Write the algorithms

1+2+3+….+100
Algorithm???

5,2,1,8,3
Algorithm???

You might also like