Professional Documents
Culture Documents
Computer Notes For Class 9th 10th
Computer Notes For Class 9th 10th
4. Name two operating systems which are used in modern mobile phones.
i. Android OS (Google Inc.)
ii. iPhone OS/iOS (Apple)
5. What difficulties a student may face if he/she is not familiar with the operating system of a computer?
i. User must know basics of operating system to give commands to the computer.
ii. Without this, he/she cannot run programs and manage files on computer.
iii. Without knowledge of operating system, a computer is useless.
10. What types of problems may a student face if no antivirus is installed in his/her computer system.
Ans. If no antivirus is installed in his/her computer then virus can damage data, software, or the computer itself.
LONG QUESTIONS:
1. Explain the main functions of operating system.
Ans. The following are the main functions of operating system.
Process Management:
i. A process is a program in execution which needs resources like processing resource, memory and I/O resources.
ii. The Operating System must allocate resources to processes the data.
Memory Management:
i. It is the process of allocating memory space to different programs.
ii. When programs are run by users, the operating system allocates portions of free memory these programs.
iii. When a program is closed, operating system will free the memory portion used by that program.
Input/output Management:
i. User communicates with computer through input/output devices such as keyboard, mouse, monitor, printer etc.
ii. Operating system uses Input/output controller to manage all the input/output devices.
File Management:
i. It is the process in which operating system organizes, stores and keeps track of files and folders.
ii. Operating System perform various operations on these files/folders like creating, opening, editing, renaming,
moving, copying, deleting and searching etc.
Resource Management:
i. The resources of a computer include microprocessor, memory and all the devices attached to the computer.
ii. Operating system automatically manages the resources of a computer when application programs are executed by user.
User Management:
i. User management is an important feature of operating system for a secure computer system.
ii. The operating system gives full control to administrator only who can install various programs and can creates new users.
iii. Operating system does not allow the users to install programs or create new users.
To change the Font Style and Effects, follow the following steps:
i. Click the Home tab.
ii. Click the dialog box launcher on the lower-right corner of the Font group.
iii. This will open the Font dialog box. Now, the user can change font styles and effects of text.
iv. Some changes that are available in the Font dialog box can be made directly from the Font group in Home tab.
ii. What is algorithm and what is the role of algorithm in problem solving?
Algorithm: A set of steps that clearly defines a sequence of operations to solve a problem is called Algorithm.
Role of Algorithm in Problem Solving: Formulating an algorithm is the first step for developing a computer program.
v. Draw any four graphical symbols used in flowchart and explain them.
Flow line:
It is a line with arrow head. It indicates the flow of control.
Start/Stop Symbol:
It is a rounded rectangular shaped. It is used to indicate the start or end of a flowchart.
Input/Output Symbol:
It is represented by parallelogram. It indicates input or output operations
Processing Symbol:
It is represented by a rectangular block. It is used for data processing operation.
Decision Symbol:
A diamond shaped symbol represents decision in flowchart and it contains a condition.
LONG QUESTIONS
ii. Write an algorithm to calculate the area of a rectangle for given breadth and length.
Step 1 Input the breadth (B) and Length (L) of a rectangle
Step 2 Calculate the area (A) by multiplying L with B
Step 3 Print A
iii. Write an algorithm that inputs length in inches and calculate and prints it in centimeters.
Step 1 Input the length in inches (LI)
Step 2 Calculate the length in cm (LCM) by multiplying LI with 2.54
Step 3 Print LCM
iv. Write an algorithm that inputs marks and prints the message “PASS” or “FAIL”. Passing marks are 33.
Step 1 Input Marks (M)
Step 2 Check if (M<33) then Print “FAIL” GOTO Step 4
Step 3 ELSE Print “PASS”
Step 4 Stop
vi. Write an algorithm to find the product of given numbers. PRODUCT = 1×3×5×7×9×11×13×15
Step 1 Start
Initialize variable K to 1 and prod = 1
K=1 Prod= 1
Step 2 Increment K by 2
K=K+2
Step 3 Find the Product
Prod=Prod × K
Step 4 Check if the value of K is less than 16
IF K<16 THEN GOTO Step 2 otherwise GOTO Step 5
Step 5 Print product
Print Prod
Step 6 Stop
vii. Write an algorithm to print multiplication table of a number in reverse order.
Step 1 Enter the number N whose table is to be generated
Step 2 Initialize the value of 1 with 10
L = 10
Step 3 Find the product of N and I
Prod= N × L
Step 4 Print N, L and Prod
Print N L and Prod
Step 5 Decrease the value of L by 1
L=L–1
Step 5 IF the value of L is > 0 THEN GOTO Step 3 Otherwise GOTO Step 6
Step 6 Stop
viii. Write a Flowchart to calculate the Write a Flowchart to that input length in inches
area of a rectangle for given breadth and length. and calculate and prints it in centimeters.
Start Start
• LI = length in inches
• LCM = length in centimeter
Area = L * B LCM = LI * 2.54
Stop Stop
Write a Flowchart to that inputs marks and prints the message “PASS” or “FAIL” Passing marks are 33.
Start
IF M < 33
Print LCM
Stop
Write a Flowchart to find the sum of given sequence. SUM = 20+25+30+40+45+50+55+60
Start
SUM 20, K = 20
SUM = SUM + K
K= K+5
YES NO
IF K < 60
Print SUM
Stop
Start
Prod = 1 , K = 1
Prod = Prod * K
K=K+2
NO YES
IF K < 16
Print Prod
J = 10
Prod = N * J
Print N, J, Prod
J=J–1
IF J > 0
Stop
Guardian Model School System
Chapter # 7 WWW & HTML
SHORT QUESTION
i. Differentiate between website and Web server.
Website Web server
A website is a collection of web pages. A Web server is a computer that makes Web pages
available through the internet
A URL is typed in Web browser and ENTER button is Web servers deliver HTML documents when a user types a
pressed to view it. URL in browser.
ii. Describe how a search engine is used for searching information on the Internet.
i. Users type in one or more keywords in a search engine.
ii. The search engine will look for matches found from all over the Web.
iii. User will see the total number of matches found.
iv. Most popular search engines are Yahoo! And Google.
LONG QUESTION `
3. Describe how background color and image are applied to Web page.
To apply a background color in a page, insert the background color attribute and for foreground color, insert text
attribute in the <body> tag
Applying Background Image:
An image can be set as background of a page using the background attribute in the <body> tag.
<body background=”image.jpg”>
OR Gate:
i. The OR gate has two or more inputs, the output of an OR gate is LOW only when all the inputs are LOW.
ii. The output is HIGH when one or more of its inputs are HIGH
iii. The logic operation of a two-input OR gate is shown in Fig, with all the possible input combinations and the
resulting output for each.
LOW HIGH HIGH
LOW HIGH
LOW HIGH HIGH HIGH
LOW HIGH
LOW HIGH
NOT Gate:
i. The NOT gate performs the functions of inversion. Therefore, it is also known as inverter. It has a single input.
ii. The output of a NOT gate is HIGH when the input is LOW and vice versa.
LOW HIGH HIGH LOW
NAND Gate:
i. The NAND gate combines the AND and NOT gates, such that the X X Y F
̅̅̅̅
XF =𝑋𝑌 0 0 1
output will be 0 only when all the inputs are 1 as shown in Fig. Y 0 1 1
ii. ̅̅̅̅ which indicates that inputs x and y
Its logic expression is F = 𝑋𝑌 1 0 1
1 1 0
are first ANDed and then the result is inverted. Inversion is indicated by a bar.
iii. Thus, a NAND gate always produces an output that is the inverse (opposite) of AND gate.
The NOR Gate:
i. The NOR gate combines the OR and Not gates, such that the X Y F
output will be 0 when any input is 1 as shown in FIG. X
F = ̅̅̅̅̅̅̅̅
𝑋+𝑌 0 0 1
0 1 0
ii. Its logic expression is F = = ̅̅̅̅̅̅̅̅
𝑋 + 𝑌, which indicates that x and y Y
1 0 0
1 1 0
are first ORed and then the result inverted. Inversion is indicated by a bar.
iii. A NOR gate always gives an output that is the inverse of OR gate.
2. Explain how NAND and NOR gates can be created using AND, OR and NOT gates.
Creating NAND Gate Using Basic Gates:
The NAND gate can be easily created by using an AND gate and a NOT gate as shown in Fig.
X F = XY
̅̅̅̅
F =𝑋𝑌
Y
F3= ̅̅̅̅̅̅
𝑋𝑌𝑍 + ̅̅̅̅
𝑋𝑌𝑍 + 𝑋̅𝑌𝑍 + 𝑋𝑌𝑍̅ F4= 𝑋𝑍̅ + ̅̅̅̅
𝑋𝑌
X Y Z 𝑋̅ 𝑌̅ 𝑍̅ ̅̅̅̅̅̅
𝑋𝑌𝑍 ̅̅̅̅𝑍
𝑋𝑌 𝑋̅𝑌𝑍 𝑋𝑌𝑍̅ F3 X Y Z 𝑋̅ 𝑌̅ 𝑍̅ 𝑋𝑍̅ ̅̅̅̅
𝑋𝑌 F4
1 1 1 0 0 0 0 0 0 0 0 1 1 1 0 0 0 0 0 0
1 1 0 0 0 1 0 0 0 1 1 1 1 0 0 0 1 1 0 1
1 0 1 0 1 0 0 0 0 0 0 1 0 1 0 1 0 0 0 0
1 0 0 0 1 1 0 0 0 0 0 1 0 0 0 1 1 1 0 1
0 1 1 1 0 0 0 0 1 0 1 0 1 1 1 0 0 0 0 0
0 1 0 1 0 1 0 0 0 0 0 0 1 0 1 0 1 0 0 0
0 0 1 1 1 0 0 1 0 0 1 0 0 1 1 1 0 0 1 1
0 0 0 1 1 1 1 0 0 0 1 0 0 0 1 1 1 0 1 1
𝑋̅𝑌𝑍 𝑋̅𝑌𝑍̅ 𝑌̅ 𝑌
𝑋̅
𝑋 𝑋𝑌𝑍̅ ̅̅̅̅
𝑋𝑌𝑍 𝑋̅𝑌𝑍 𝑋̅𝑌𝑍̅
𝑋̅
𝑍̅ 𝑍̅ 𝑋𝑌𝑍 𝑋𝑌𝑍̅
𝑍 𝑋
F1= 𝑋̅𝑌𝑍 + 𝑋̅𝑌𝑍̅ + 𝑋̅𝑌𝑍̅ + 𝑋𝑌𝑍̅ 𝑍̅ 𝑍̅
F1= 𝑋̅𝑌(𝑍 + 𝑍̅) + 𝑌𝑍̅(𝑋̅ + 𝑋) 𝑍
F1= 𝑋̅𝑌 + 𝑌𝑍̅ F2 = ̅̅̅̅
𝑋𝑌𝑍 + 𝑋̅𝑌𝑍 + 𝑋̅𝑌𝑍 + 𝑋̅𝑌𝑍̅ + 𝑋𝑌𝑍 + 𝑋𝑌𝑍̅
F2 = 𝑋̅𝑍(𝑌̅ + 𝑌) + 𝑋̅𝑌(𝑍 + 𝑍̅) + 𝑋𝑌(𝑍 + 𝑍̅)
F2 = 𝑋̅𝑍 + 𝑋̅𝑌 + 𝑋𝑌
F2 = 𝑋̅𝑍 + 𝑌(𝑋̅ + 𝑋)
F2 = 𝑋̅𝑍 + 𝑌
F3= ̅̅̅̅̅̅
𝑿𝒀𝒁 + ̅̅̅̅
𝑿𝒀𝒁 + 𝑿̅ 𝒀𝒁 + 𝑿𝒀𝒁
̅ ̅ + ̅̅̅̅
F4= 𝑿𝒁 𝑿𝒀
𝑌̅ 𝑌 F4= 𝑋𝑍̅(𝑌 + 𝑌̅) + 𝑋𝑌
̅̅̅̅ (𝑍 + 𝑍̅ )
F4= 𝑋𝑌𝑍 + 𝑋𝑌𝑍 + ̅̅̅̅
̅ ̅̅̅̅ 𝑋𝑌𝑍 + ̅̅̅̅̅̅
𝑋𝑌𝑍
̅̅̅̅̅̅
𝑋𝑌𝑍 ̅̅̅̅𝑍
𝑋𝑌 𝑋̅𝑌𝑍 𝑌̅ 𝑌
𝑋̅
𝑋 ̅̅̅̅̅̅
𝑋𝑌𝑍 ̅̅̅̅𝑍
𝑋𝑌
𝑋̅
𝑍̅ 𝑍̅ 𝑋 ̅̅̅̅
𝑋𝑌𝑍 𝑋𝑌𝑍̅
𝑍
𝑍̅ 𝑍̅
𝑍
̅̅̅̅ + 𝑋𝑌𝑍̅ + ̅̅̅̅̅̅
F4= 𝑋𝑌𝑍 𝑋𝑌𝑍 + ̅̅̅̅
𝑋𝑌 𝑍
F4= 𝑋𝑍̅(𝑌̅ + 𝑌) + 𝑋𝑌
̅̅̅̅(𝑍̅ + 𝑍)
F4= 𝑋𝑍̅ + ̅̅̅̅
𝑋𝑌
Guardian Model School System
Chapter # 3 Input and Output Handling
SHORT QUESTION
i. Why format specifier is used? Explain with examples.
A format specifier is computer code that tells about the data type, field, width and the format according to which a value
is to be printed or read from an input device. Following are the commonly used format specifiers:
%d = Decimal Integer %i = integer %ld = long decimal integer %f = floating-point (decimal notation)
%g = floating-point (exponential notation) %e = floating-point (%f or %g, whichever is shorter)
%c = single character %s = string
ii. Describe the functions of the following operators? i) Relational ii) Logical iii) Conditional
A) Relational Operators:
i. These are used to compare two values of the same type.
ii. These are used in expressions when a decision is to be based on a condition.
iii. After evaluation of a relational expression, the result produced is either True of False.
iv. Relational operators are used in programming for decision making.
v. There are six types of relational operators in C language. These are described in table below:
Operator Definition
== Equal to
!= Not equal to
< Less than
> Greater than
<= Less than or equal to
>= Greater than or equal to
B) Logical operators:
i. Logical operators are used for building compound conditions.
ii. A single condition is built using a relational operator in an expression.
iii. If we need to build more than one condition for some action to take place programming, then we have to form
compound condition. They have following types:
Operator Definition
&& AND
|| OR
! NOT
C) Conditional Operator
i. A conditional operator is a decision-making operator. It has the following form.
Condition? expression1: expression2:
ii. When this statement is executed, the condition is evaluated. If it is true, the entire conditional expression takes on the
value of expression1. If it is false, the expression takes on a value and can therefore be used in assignment statements.
Write a program that reads three numbers and prints their sum, product and
average.
#include <stdio.h>
int maint()
{
int num1, num2, num3, sum, prod, avg;
printf(“Enter the three numbers separated by ‘,’\n”);
scanf(“%d, %d, %d, &num1, &num2, &num3);
sum = num1 + num2 + num3;
prod = num1 * num2 * num3;
avg = sum/3;
prinf(“the sum of the three numbers is : %d\n”,sum);
printf(“the prod of the three numbers is : %d\n”,prod);
printf(“the average of the three numbers is : %d\n”, avg);
}
Write a program that reads the length and width of a rectangle and prints its
area.
#include <stdio.h>
main()
{
float length, width, area;
printf(“Enter length of rectangle:”);
scanf(“%f”, &length);
printf(“Enter width of rectangle:”);
scanf(“%f”, &width);
area= length*width;
printf(“Area of rectangle - %f sq. units “,area);
}
Write a program that reads the length of one side of a cube and prints its
volume.
#include <stdio.h>
#include <conio.h>
main()
{
float side, volume;
printf(“Enter length of any side of cube\n”);
scanf(“%f”, &side);
printf(“Volume of Cube: %0.4f\n, volume);
}
Write a program that reads name and address of a person and prints it on
the screen using gets() and puts() functions.
#include <stdio.h>
#include <string.h>
int main()
{
char name[50], add[50];
printf(“Enter your name:”);
gets(name);
printf(“Enter your address:”);
gets(add);
printf(“Your name is:”);
puts(name);
printf(“Your address is:”);
puts(add);
}
Guardian Model School System Chapter # 4 Hazrat Asma (RA)
Q-1. What happened when Abu Jehl asked about Hazrat Abu Bakar (RA)?
Ans. Hazrat Asma (RA) simply posed a counter question. She politely replied, “How would I know”?
Q-2. Why was Abu Quaffa (RA) worried?
Ans. He was worried about the gold, jewels and money that had taken away by Hazrat Abu Bakar (RA).
Q-3. How did Hazrat Asma (RA) console her grandfather?
Ans. She put some pebbles at the place of money and jewels and covered them with a piece of cloth. She made her
grandfather touch them and said that Hazrat Abu Bakar (RA) had left all his wealth at home. In this way, she wisely
consoled her grandfather.
Q-4. Who was Hazrat Abdullah Bin Zubair (RA)?
Ans. He was the son of Hazrat Asma (RA).
Q-5. Which incident in the story showed Hazrat Asma’s (RA) love and respect for the Holy Prophet (SAW)?
Ans. Every night, without taken any care for her life, she would quietly venture towards the cave of Thaur to supply food
to the Prophet of Allah (SAWW). It shows her love and respect for the Holy Prophet (SAWW).
Q-6. Which incident in the story tells about the generosity of Hazrat Asma (RA)?
Ans. When she inherited a garden after the death of her sister Hazrat Ayesha (RA), She instantly sold it and gave away all
the money to the poor and needy people, and felt more pleasure than receivers.
Q-7. What message do you get from the life of Hazrat Asma (RA)?
Ans. We get the message, that we should bravely face every calamity of life for the cause of right path. We should keep
walking on the right path that lead us to Allah and his Prophet (SAW).
Q-8. “Her life would always be a beacon of light for all of us” How?
Ans. She was brave, wise, courageous and generous. She did not care for her life but she served the Prophet of Allah
(SAWW) through thick and thin. She faced every calamity of life with patience and valor. So, we can say that her life
would be a beacon of light for all of us.