Вы находитесь на странице: 1из 19

Question: 1

What do you mean by programming language? How many types of programming language are
there?

PROGRAMMING LANGUAGE
Defi nition : A programming language is a formal computer
language or constructed language designed to communicate instructions to
a machine, particularly a computer. Programming languages can be used to
create programs to control the behavior of a machine or to express algorithms
Or
A set of rule that provide a way to telling computer what operation to perform is
called programming language

TYPES OF PROGRAMMING LANGUAGE


There are following types of programming language;

1. Machine language

low level language

2. Assembly language

3. High level language


MACHINE LANGUAGE: Every creation of this universe has its own language.
likewise, computer, has a language that is Machine language (machine level
language ) for instruction computer to perform a specific task .it is also called a
binary language .Machine language represents data and program instructions as 0s
and 1s (zeros and ones),binary digits corresponding to the ON and OFF electrical
states in the computer. Each computer has its own unique machine language.
ASSEMBLY LANGUAGE: Assembly language is also a next level of programming
language. In assembly language, the statements are written in symbolic code
(termed as mnemonics) that is easier for human to read and write as compared to
machine language. Each assembly language corresponds to one machine language
statement.
HIGH LEVEL LANGUAGE: It is also called an English Oriented Language .Programs
was written in English like manners, thus making them more convenient to use.
Machine language is still difficult because it requires detailed knowledge of a
specific computer Thats why high level language such as Fortran ,Pascal ,C , etc
were developed .As a result ,a programmer could accomplish more with less efforts

Types of high level language;


There are three basics types of high level language
1.
2.
3.
4.
5.
6.

FORTRON
COBAL
BASIC
PASCAL
ADA
C-language.

Question: 2
Define software .Discuss different types of software.

SOFTWARE
Defi nition: Software is that part of a computer system that consists of encoded
information or computer instructions, in contrast to the physical hardware from
which the system is built.
Or
Software is a general term used for computer program. A computer program is a
planned, step by step set of instructions that directs the computer what to do and
how to do. It turns the data into information that makes computer useful .Without
software a computer is like a human without brain.

TYPES OF SOFTWARE
Generally speaking, software can be categorized as:
1. System software
2. Application software
SYSTEM SOFTWARE: System software is that software which we can used to
control the system and also used for run applications. System software is the
program directly related to the computer hardware and performs tasks associated
with controlling and utilizing computer hardware.
Categories of system software;
There are following categories of system software.
1. Operating system
2. Language translator
i.
Interpreter
ii.
Compiler
iii.
Assembler
3. Data management software
4. Editors

5. Utility software
APPLICATION SOFTWARE: Application software is programs that help the user to
perform a specific job.
For example: application software enables a user;

To
To
To
To

write a letter
create a drawing
make a report
prepare accounts

It helps the user work faster; more efficiently and thus provide more productivity
than manual performance.

TYPES OF APPLICATION SOFTWARE


Application software can be grouped into two broad categories;
1. General purpose application software
2. Special purpose application software
Question: 3
What is an operating system? Write down characteristics of DOS.

OPERATING SYSTEM
Defi nition: Operating system is a set of programs that controls and supervisees
the hardware of a computer and provides services to application software,
programmers and users of computer. Without an operating system computer cannot
do anything useful. Without an operating system computer cannot recognize any
command.

TYPES OF OPERATING SYSTEM


Following are some of the popular operating system used in personal computers.
1.
2.
3.
4.
5.
6.

DOS
Windows
UNIX
LINUX
XP
Solaris.

CHARACTERISTICS OF DOS
1. It is called DOS (Disk Operating System) because it can reside on a single
disk (Floppy disk).
2. The process of loading the disk operating system into memory is called boot
strapping or booting the system.

3.
4.
5.
6.

It is developed by a very well known company Microsoft Corporation.


DOS environment did not support the features of clipboard.
It did not use space or any special character in your file.
DOS is not a multi tasking operating system. It can do not task at a time.

Question: 4
Write the full forms of the following.

SHORT HAND

FULL FORMS

1. IBM

International Business Machine

2. HDD

Hard Disk Drive

3. CRT

Cathode Ray Tube

4. ACSII

American Standard Code For Information Interchange

5. BPI

Bytes Per Inch

6. COBAL

Common Business Oriented Language

7. LAN

Local Area Networking

8. 4GL

Fourth Generation language

9. RMDIR

Remove Directory

10.CHDIR

Change directory (DOS command)

11.BASIC

Beginners All Purpose Symbolic Instruction Code

12.LCD

Liquid Crystal Display

13.FORTRAN

Formula Translation

14.EBCDIC

Extended Binary Coded Decimal Interchange Code

15.HGA

Hercules Graphical Adapter

Question: 5
Define types of computer according to their size.

ACCORDING TO SIZE

Supercomputers

Mainframe Computers

Minicomputers

Workstations

Microcomputers, or Personal Computers

Supercomputers: Supercomputer is widely used in scientific applications such


as aerodynamic design simulation, processing of geological data.

Supercomputers are the most powerful computers. They are used for problems
requiring complex calculations.

Because of their size and expense, supercomputers are relatively rare.

Supercomputers are used by universities, government


businesses.

agencies, and large

Mainframe Computers: Mainframe is usually slower, less powerful and less


expensive than supercomputers. A technique that allows many people at terminals,
to access the same computer at one time is called time sharing. Mainframes are
used by banks and much business to update inventory etc .

Mainframe computers can support hundreds or


massive amounts of input, output, and storage.

thousands of users, handling

Mainframe computers are used in large organizations where many users need
access to shared data and programs.

Mainframes are also used as e-commerce servers, handling transactions


over the Internet.

Minicomputers: Minicomputer are smaller than mainframe, general

purpose
computers, and give computing power without adding the prohibitive expenses
associated with larger systems. It is generally easier to use.

Minicomputers usually have multiple terminals.


Minicomputers may be used as network servers and Internet servers.

Workstations

Workstations are powerful single-user computers.

Workstations are used for tasks that require a great deal of number-crunching
power, such as product design and computer animation.

Workstations are often used as network and Internet servers.

Microcomputers or Personal Computers: Microcomputers or Personal


computer is the smallest, least expensive of all the computers. Micro computers
have smallest memory and less power, are physically smaller and permit fewer
peripherals to be attached.


Microcomputers are more commonly known as personal computers. The term
PC is applied to IBM-PCs or compatible computers.

Desktop computers are the most common type of PC.

Notebook (laptop) computers are used by people who need the power of a
desktop system, but also portability.

Handheld PCs (such as PDAs) lack the power of a desktop or notebook PC, but
offer features for users who limited functions and small size.

Personal Computers (PC)


Desk Top
Lap Top
Palm Top
PDA
Question: 6
Differentiate;

Data and Information.


DOS and Windows Operation System.
Internal and External Command of DOS.
Sequential access and random access
Command and statement.

DATA

INFORMATION

1. Data is a collection of facts and


figures.
2. A set of words would be data.

Processed data is called information.

3. Data may be of two types.


i.
Quantities
ii.
Qualities

Information depends upon the respective


type of data.

DOS
1. DOS has a CUI (Command User
Interface).

A text would be information.

WINDOWS OPERATION
SYSTEM
Windows has a GUI (Graphical User
Interface).

2. In DOS instruction are typed


through commands.
3. DOS is a single user operating
system.

INTERNAL COMMAND OF
DOS
1. These are the command that is
loaded automatically in a memory
of computer (RAM) at the time of
booting.
2. To run all the internal command
you dont have to set a path
3. Internal command is stored in
command interpreter
(command.comfile).

SEQUENTIAL ACCESS
1. Volume location is limited by the
trigger prefix or by manual
specification
2. Operators need to define volumes
and specify their sizes, or define
space triggers to automatically
allocate space when a threshold is
reached.
3. Sequential access performed by
node and file space.

In windows instruction are controlled by


clicking picture on screen or making
selection from menu.
Windows is a multiuser operating system.

EXTERNAL COMMAND OF
DOS
These are the command that has no
loaded automatically in memory of
computer (RAM) at the time of booting.
To run all the external command you
have to set a path.
External command is stored separately
on a disk as a program.

RANDOM ACCESS
A list of directories can be specified. If
directories correspond with file systems,
performance is optimized.
Operators can a define space triggers to
automatically allocate space when a
threshold is reached.

Random access performed by volume.

COMMAND

STATEMENT

1. A command is an operating
system instruction or other
system instruction SQL may fall
into the categories.
2. A command is an action.

A statement is an instruction that will be


translated into machine code by the
compiler or the interpreter.
A statement is a unit of an imperative
program.

3. Statement is the part of computer


program and run in compiler and
indirect mode.

Command are generally executable


indirect in mode.

Question: 7
Draw the block diagram of CPU and explain the following.
i.

ALU

ii.

Control unit

BLOCK DIAGRAM OF CPU

ALU (ARITHEMATIC LOGICAL UNIT)


Defi nition: ALU is the part of CPU where arithmetic operation such as, addition,
subtraction, multiplication, division as well as logical operation such as comparison
between two pieces of data is performed.

Function of ALU:

The ALU performs the basic functions on data received from the primary
storage.
The ALU performs arithmetic and logical operations.

Working Process:

The ALU includes a group of registers. The registers are high speed volatile or
temporary memory location built directly into the CPU. There are 14 basic registers
shared by ALU and CU.

Example:
The control unit might load two numbers from memory into the registers in the ALU.

CU (CONTROL UNIT)
Defi nition: The control unit is a part of CPU where all the computers resources
are managed. It works like a traffic cop directing the flow of data between the
components of the CPU and to and from other device. Its also includes registers.

Function
The control unit

Regulates operations in a computer by directing data flow within the CPU.


Controls the execution of program.
Selects program statements from memory.
Controls input and output devices.

Question: 8
Write down briefly the function of CPU.

FUNCTIONS OF CPU (CENTRAL PROCESSING UNIT)


The CPU processes instructions it receives in the process of decoding data. In
processing this data, the CPU performs four basic steps:
Fetch Each instruction is stored in memory and has its own address. The processor
takes this address number from the program counter, which is responsible for
tracking which instructions the CPU should execute next.
Decode All programs to be executed are translated to into Assembly instructions.
Assembly code must be decoded into binary instructions, which are understandable
to your CPU. This step is called decoding.
Execute While executing instructions the CPU can do one of three things: Do
calculations with its ALU, move data from one memory location to another, or jump
to a different address.
Store The CPU must give feedback after executing an instruction and the output
data is written to the memory.

Question: 9
Define a language translator and write its types.

LANGAGE TRANSLATOR
Computer can only understand programs in machine languages but we write
programs in high level languages. Therefore, there must be a language translator
which translates high level language into machine language so that computer can
act upon our instruction.

TYPES OF LANGUAGE TRANSLATOR


There are three types of language translator,
1. Assembler
2. Complier
3. Interpreter
ASSEMBLER
An assembler is a program that converts assembly language program into machine
language. Computer does understand only machine language; assembly languages
facilitate programmers to write programs easily but still needs to convert the
assembly language program into machine understandable form. The assembler is a
language translator for a low level programming language.
COMPLIER
Compiler is a translator, which translate high level Source program into low level
Objectprogram. Compiler translates the whole program at a time and gives an
error list to be removed. These translators are used to translate entire program at
once and store their translated program on disk.
INTERPRETER
Interpreter is a translator program which translates a Source program into object
program. The interpreter translates the program every time you will execute
because it translates one instruction at a time. It does not make any object file.
Interpreters are easy to write and they do not required large memory space in the
computer.

Question: 10
Why do you need language translator?
We need language translator in system software because computer cant
understand our language. Therefore translator converts high level language into
low level language &vice versa as computer can only understand in binary format.

we need language translator in a system software because computer cant


understand our language .Therefore translator converts high level language into low
level language &vice versa as computer can only understand in binary format.
Question: 11
Define virus and write different names of viruses.

VIRUS
A virus is a hidden program, which can affect other program by modifying than and
causing the data loss. It attached itself to other programs and executed secretly
every term, they most program are executed. The virus replicated itself with a
computer system. Some virus hidden in the computer can affect the computer at a
particular time called time bomb virus.

TYPES OF VIRUSES
There is large number of virus present in the computer world. These viruses include;

Brain (developed by a group of Pakistanis)


Joshi
Jerusalem
Friday 13th
Chernobyl .etc

Question: 12
Write short note on the following topics.
i.
ii.
iii.
iv.
v.
vi.
vii.
viii.
ix.
x.

1.

Icon.
Windows explorer.
Number system.
History of basic.
Reversed or key word.
Application of computer in education.
Operating system.
Loop and its types.
Purpose of lines numbers in basic.
Main memory.

ICON

An icon is a small color full graphical picture that represents an object like a file,
folder, any label in a computer. Every icon has a label, which identifies it. The labels
can be changed. Windows operating system use different icons to represent files,
folders and applications, icon found on desktop are normally left aligned.
Microsoft Windows and the Apple Mac OS, to help quickly identify a type of file or

program associated with the icon. The image to the right is an example of My
Computer icons in different versions of Microsoft Windows.

Google chrome icon.

Changing the position of icon.

Select the icon whose position you want to change by left clicking with the
mouse.
Hold down left button of the mouse while moving the pointer to new location
of the desktop or to the folder where you want to place the icons.
Released the mouse button now.
Icon has been moved to a new location.

Changing the name or label of icon.

Move mouse pointer to the icon whose name you want to change.
Click the right button of the mouse, a menu will open.
Click on the Rename command from it.
Label of the icon will be highlighted and cursor will flash in it.
Now types the new name and pass entre key at the end.
Name or label of the icon has been changed.

2.
EXPLORER

WINDOWS

Windows Explorer is a graphical file management utility for the Windows operating
system (OS).
Windows Explorer, which was introduced with Windows 95, was later renamed File
Explorer. Each time that a computer user accesses a disk or opens a folder
containing files, they are using the Windows/File Explorer utility. The goal of the file
management utility is to allow users to conveniently work with the files and
directories located on any connected disk. When a file is selected within the

Windows/File Explorer interface, users can select from a variety of context-sensitive


actions such as renaming, moving, copying, publishing, emailing, printing or
deleting the file. Entire folders can also be opened, explored, shared, copied, cut,
pasted, moved or deleted. Files can be searched or dragged and dropped between
folders, and folders can be moved into other folders and disk drives as desired.
Windows/File Explorer can present files and folders in several different formats such
as thumbnail image arrays, icons, lists and details (including name, size, type, date,
time and other information). The choice of display format depends on the users
preferences and the type of content being explored. For example, a folder with an
extensive library of image files may be displayed in thumbnail format, while a folder
of documents might be better viewed as a detailed list.

3. NUMBER SYSTEM
A set of values used to represent different quantities is known as Number
System". For example, a number system can be used to represent the number of
students in a class or number of viewers watching a certain TV program etc. The
digital computer represents all kinds of data and information in binary numbers. It
includes audio, graphics, video, text and numbers. The total number of digits used
in a number system is called its base or radix. The base is written after the number
as subscript such as 51210.
Some important number systems are as follows.
Decimal number system
Binary number system
Octal number system
Hexadecimal number system
The decimal number system is used in general. However, the computers use binary
number system. The octal and hexadecimal number systems are used in the
computer.

4. HISTORY OF BASICS
One of the earliest machines designed to assist people in calculations was
the abacus which is still being used some 5000 years after its invention.
In 1642 Blas Pascal (a famous French mathematician) invented an adding machine
based on mechanical gears in which numbers were represented by the cogs on the
wheels.

Englishman, Charles Babbage, invented in the 1830's a "Difference Engine" made


out of brass and pewter rods and gears, and also designed a further device which
he called an "Analytical Engine".
Augusta Adam Byron (later Countess of Lovelace) was an associate of Babbage who
has become known as the first computer programmer.
An American, Herman Hollerith, developed (around 1890) the first electrically driven
device. It utilized punched cards and metal rods which passed through the holes to
close an electrical circuit and thus cause a counter to advance. This machine was
able to complete the calculation of the 1890 U.S. census in 6 weeks compared with
7 1/2 years for the 1880 census which was manually counted.
In 1936 Howard Aiken of Harvard University convinced Thomas Watson of IBM to
invest $1 million in the development of an electromechanical version of Babbage's
analytical engine. The Harvard Mark 1 was completed in 1944 and was 8 feet high
and 55 feet long.
At about the same time (the late 1930's) John Atanasoff of Iowa State University and
his assistant Clifford Berry built the first digital computer that worked electronically,
the ABC (Atanasoff-Berry Computer). This machine was basically a small calculator.
In 1943, as part of the British war effort, a series of vacuum tube based computers
(named Colossus) were developed to crack German secret codes. The Colossus
Mark 2 series (pictured) consisted of 2400 vacuum tubes.

5. RESEVERED OR KEY WORDS


Often found in programming languages and macros, reserved words are terms or
phrases appropriated for special use that may not be utilized in the creation
of variable names. For example, "print" is a reserved word because it is a function in
many languages to show text on the screen.
Reserved words are used in operating systems as a method of identifying a device
file or other service. Below is a listing of Microsoft reserved words in MS-DOS and
Windows operating systems. When attempting to use any of the below reserved
words as a name of a file, or in a command you may encounter and unusual
response. For example, attempting to save a file as CON or CON.txt may generate a
reserved file name or access denied error or say the file already exists.
Reserved Word
AUX

What it is
Auxiliary port aka Serial Port COM1

CON

Short for console, which Microsoft describes as the display monitor.

COM1

COM port

COM2

COM port

COM3

COM port

COM4

COM port

LPT1

LPT port

LPT2

LPT port

LPT3

LPT port.

NUL

NULL

PRN

Printer aka LPT1

6. APPLICATIONS OF COMPUTER IN
EDUCATION
This course is designed to help teachers become familiar with various aspects of
computer applications in educational settings. It is expected that each learner will
have had some experience with computers and come to the course with questions,
inquiries and interests in various issues related to the educational application of
computers on both the theoretical and practical levels.
Computer applications in education is a broad and changing term due to the
breadth of the area of study and the rapid and ever-changing nature of technology.
Computer applications include, but are not limited to, desktop publishing and
presentations, computer use in classrooms, telecommunications and distance
education, computer hardware and software, networking, lab administration,
multimedia presentations, and publishing. Obviously, we cannot cover them all in
just one fifteen week course. Additionally, it does not help to learn to use

technology in isolation, especially when technology changes quickly and


dramatically. The learning of technology must be integrated in daily classroom
teaching activities within the context of educational goals for it to be meaningful.
Therefore, in this course, we will incorporate an integrated approach and learn to
use technology in the process of applying it to resolve teaching and learning issues.
We will use problem-based learning as a channel for our exploration. We will discuss
why and how to integrate computers in our teaching. I hope that by doing so, we
will critically re-examine and positively transform our ways of teaching with
computer and new technologies.

7. OPERATING SYSTEM
Operating system is software that works as an interface between a user and
the computer hardware. The primary objective of an operating system is to make
computer system convenient to use and to utilize computer hardware in an efficient
manner. The operating system performs the basic tasks such as receiving input
from the keyboard, processing instructions and sending output to the screen.
The Software is the Non-Touchable Parts of the Computer , and Softwares are those
which are used for Performing an Operation So that Softwares are just used for
Making an Application but hardwares are those which are used for Performing an
Operation .
Operating system is software that is required in order to run application programs
and utilities. It works as a bridge to perform better interaction between application
programs and hardware of the computer. Various types of operating systems' are
UNIX, MS-DOS, MS-Windows - 98/XP/Vista, Windows-NT/2000, OS/2 and Mac OS.
Operating system manages overall activities of a computer and the input/output
devices attached to the computer. It is the first software you see when you turn on
the computer, and the last software you see when the computer is turned off. It is
the software that enables all the programs you use.

8. LOOP AND ITS TYPES


A Computer is used for performing many Repetitive types of tasks The Process of
Repeatedly performing tasks is known as looping .The Statements in the block may
be Executed any number of times from Zero to Up to the Condition is True. The Loop
is that in which a task is repeated until the condition is true or we can say in the
loop will Executes all the statements are until the given condition is not to be false.

Here are generally used for repeating the statements. In this There is Either Entry
Controlled loop or as Exit Controlled Loop We know that before Execution of
Statements all Conditions are Checked these are Performed by Entry Controlled
Loops Which First Checks Condition And in Exit Controlled Loop it Checks Condition
for Ending Loop Whether given Condition is False or not if a Loop First Checks
Condition For Execution then it is called as Entry Controlled Loop and if a Loop
Checks Condition after the Execution of Statement then they are Called as Exit
Controlled Loops.

In The loop generally there are three basic operations are performed
1) Initialization
2) Condition check
3) Increment
There are the three types of loops in the java
1) While
2) Do-while
3) For
All these are used for performing the repetitive tasks until the given condition is not
true.
1) While: - While Loop is Known as Entry Controlled Loop because in The while loop
first we initialize the value of variable or Starting point of Execution and then we
check the condition and if the condition is true then it will execute the statements
and then after it increments or decrements the value of a variable. But in the while
loop if a Condition is false then it will never Executes the Statement So that For
Execution, this is must that the Condition must be true.
2) Do while: - This is Also Called as Exit Controlled Loop we know that in The while
loop the condition is check before the execution of the program but if the condition
is not true then it will not execute the statements so for this purpose we use the do
while loop in this first it executes the statements and then it increments the value of
a variable and then last it checks the condition So in this either the condition is true
or not it Execute the statement at least one time.
3) For: - In This loop all the basic operations like initialization, condition checking
and incrementing or decrementing all these are performed in only one line. This is
similar to the while loop for performing its execution but only different in its syntax.

9. PURPOSE OF NUMBER LINE IN


BASIC
In basic mathematics, a number line is a picture of a graduated straight line that
serves as abstraction for real numbers, denoted by. Every point of a number line is
assumed to correspond to a real number, and every real number to a point.[1]
Often the integers are shown as specially-marked points evenly spaced on the line.
Although this image only shows the integers from 9 to 9, the line includes all real
numbers, continuing forever in each direction, and also numbers not marked that
are between the integers. It is often used as an aid in teaching
simple addition and subtraction, especially involving negative numbers.

In advanced mathematics, the expressions real number line, or real line are
typically used to indicate the above-mentioned concept that every point on a
straight line corresponds to a single real number, and vice versa.
If a particular number is farther to the right on the number line than is another
number, then the first number is greater than the second (equivalently, the second
is less than the first). The distance between them is the magnitude of their
differencethat is, it measures the first number minus the second one, or
equivalently the absolute value of the second number minus the first one. Taking
this difference is the process of subtraction.
Thus, for example, the length of a line segment between 0 and some other number
represents the magnitude of the latter number.
Two numbers can be added by "picking up" the length from 0 to one of the
numbers, and putting it down again with the end that was 0 placed on top of the
other number.

10. MAIN MEMORY


Main memory is where programs and data are kept when the processor is actively
using them. When programs and data become active, they are copied from
secondary memory into main memory where the processor can interact with them.
A copy remains in secondary memory.
Main memory is intimately connected to the processor, so moving instructions and
data into and out of the processor is very fast.
Main memory is sometimes called RAM. RAM stands for Random Access Memory.
"Random" means that the memory cells can be accessed in any order. However,
properly speaking, "RAM" means the type of silicon chip used to implement main
memory.
When people say that a computer has "512 megabytes of RAM" they are talking
about how big its main memory is. One megabyte of memory is enough to hold
approximately one million (106) characters of a word processing document. (There
will be more about bytes and megabytes later on in these notes.)
Nothing permanent is kept in main memory. Sometimes data are placed in main
memory for just a few seconds, only as long as they are needed.

Вам также может понравиться