SEE (Grade Promotion) 2078 – 2022
Opt II Computer Science [B]
Group A
1. Answer the following
questions in one sentence:
a) What
is search engine?
Ans: A search engine is
an online tool that helps users find information on the internet using keywords
or phrases and provide relevant results.
b) What
is the business done through the internet called?
The business
done through the internet is called e-commerce.
c) What
is the default size of text field in MS-Access?
Ans: The default extension of Ms-Access is :
.mdb (2003
version) and .accdb(2007 version).
d) Which
data type is used to store photo in MS-Access?
Ans: The
suitable data type to store photographs of students in MS-Access is OLE object.
e) What
is looping?
Ans: Looping is the
process of repeating the execution of a statement or a block of statements
until a specific condition is satisfied.
f) List
any two data types used in C-Programming language.
Any two data
types used in C-Programming language are int and char.
2. Write
appropriate technical term for the following:
a) A
program that can disinfect a file from virus. Antivirus software
b) Learning
through the electronic media. E-learning
3. Write
the full form of the following.
a) G2G – Government to
Government
b) ISP
– Internet Service Provider
4. Answer
to the following questions:
a) What is network topology?
List any two types of network topology.
Network topology refers to the layout or inter - connected
pattern of computers and devices in a network.
Any two
types of network topology are bus topology and ring topology.
b) What
is antivirus software? Name any two popular antivirus software.
Ans: Antivirus software is a program that
scans, detects, and removes malicious software from a computer or device to
protect it from security threats.
Any two
popular antivirus software are Kaspersky and NOD 32.
c) What
is cyber law and cyber crime?
Ans The law which
governs the legal issues in the cyber space regarding the internet or WWW for
digital data processing and transaction is called cyber law.
Cyber crime refers to criminal activities that are
carried out using computers or the internet.
d) What
is virtual reality? Write any two areas where virtual reality are used.
Ans:
Virtual Reality (VR) is a technology that creates a simulated (virtual)
world where users can feel and interact with things as if they are real, using
devices like VR headsets and gloves.
Any two
areas where virtual reality is used are : Gaming and Education & Training (medical
or flight training).
e) What
is password? Write any two importance of password protection.
Ans: A password is a
secret word or phrase used to secure access to accounts or systems, ensuring
only authorized users can enter.
Any
two importance of password protection are:
1.
Password
secures the data by protecting from unauthorized access.
2.
It
safeguards personal information from being stolen or misused.
f)
What is DBMS? Write four objects of MS-Access.
Ans: DBMS is a
computerized system that stores data, processes them and provides information
in an organized form.
Any
four objects of MS-Access are Table, Form, Query and Report.
g)
What are validation text and validation rule?
Ans: Validation Text is
a field property which displays an error message that appears if the data
entered is invalid according to the specified validation rule.
Validation Rule is a field property which is used to
limit the values that can be entered into a field.
h)
What is form? Write any two advantages of it.
Ans: Form is one of the
MS-Access database objects which provides graphical interface to view, modify
and add data in a table or multiple linked tables.
Any
two advantages of form are:
1.
Form
displays complete record one at a time, so we can view and modify records using
the form.
2.
Forms
provides GUI (Graphical Users Interface) using which users interact with
MS-Access database.
i)
What is record? Why is primary key necessary in record?
Ans: A record is a row
in a table which contains information about single items in a database. Record
is complete set of information.
A primary
key is necessary in a database record because it reduce and control duplication of
the record in a table, sets the relationship between tables and identifies each
record of a table uniquely.
5.
Write down the output of the given program:
DECLARE SUB
Series(A)
CLS
A=20
CALL
Series(A)
END
SUB
Series(A)
FOR K=1 to 5
PRINT A;
A=A+10
NEXT K
END SUB
Dry
Run Table
A |
K=1 to 5 |
PRINT A; |
A=A+10 |
20 |
1 to 5 yes |
20 |
20+10=30 |
30 |
2 to 5 yes |
30 |
30+10=40 |
40 |
3 to 5 yes |
40 |
40+10=50 |
50 |
4 to 5 yes |
50 |
50+10=60 |
60 |
5 to 5 yes |
60 |
60+10=70 |
70 |
6 to 5 no Loop exits |
|
|
The
output of the program is:
20 30 40 50
60
6.
Re-Write the given program after correcting the bugs:
REM program
to make a word reverse
DECLARE
FUNCTION Rev$(N$)
CLS
INPUT “Enter
a word”; N$
DISPLAY
“Reversed is”; Rev$(N$)
END
FUNCTION
Rev$(N$)
FOR
K=LEN$(N$) To 1 STEP-1
B$=B$+MID$(N$,1,K)
NEXT K
B$=Rev$
END FUNCTION
Debugged
Program
REM program
to make a word reverse
DECLARE
FUNCTION Rev$(N$)
CLS
INPUT “Enter
a word”; N$
PRINT “Reversed is”; Rev$(N$)
END
FUNCTION Rev$(N$)
FOR K=LEN (N$)
To 1 STEP-1
B$=B$+MID$(N$,K,1)
NEXT K
Rev$=B$
END FUNCTION
7.
Study the following program and answer the given questions:
DECLARE
FUNCTION SUM(N)
CLS
INPUT “Enter any number”; N
X=SUM(N)
PRINT “The
sum of individual digit is “; X
END
FUNCTION
SUM(N)
WHILE
N<>0
R=N MOD 10
S=S+R
N=INT(N/10)
WEND
SUM=S
END FUNCTION
a)
Write the function of INT.
Ans: The INT
function returns the integer part of a number, removing the decimal part.
b)
How many times does the WHILE ….WEND loop repeat if the value of N is 123?
Ans: The
WHILE ….WEND loop repeats 3 times if the value of N is 123.
8. Convert/Calculate as per the
instruction:
i)
(11001101)2 = (?)16
Soln:
Paired Binary Digit |
1100 |
1101 |
Binary Equivalent value |
C |
D |
(10110011)2 = (CD)16
ii) (524)10 =
(?)2
2 |
524 |
Remainder |
2 |
262 |
0 |
2 |
131 |
0 |
2 |
65 |
1 |
2 |
32 |
1 |
2 |
16 |
0 |
2 |
8 |
0 |
2 |
4 |
0 |
2 |
2 |
0 |
2 |
1 |
0 |
2 |
0 |
1 |
(524)10 = (1000001100)2
iii)
(1010)2 ´ (110)2 – (1011)2 = (?)2
|
|
1 |
0 |
1 |
0 |
|
|
× |
1 |
1 |
0 |
|
|
0 |
0 |
0 |
0 |
|
1 |
0 |
1 |
0 |
× |
1 |
0 |
1 |
0 |
× |
× |
1 |
1 |
1 |
1 |
0 |
0 |
|
- |
1 |
0 |
1 |
1 |
1 |
1 |
0 |
0 |
0 |
1 |
(1010)2 ´ (110)2 –
(1011)2 = (110001)2
iv) (10110)2 ÷
(101)2
101) |
10110( |
100 |
|
-101 |
|
|
00010 |
|
|
-
0 |
|
|
10 |
|
Quotient = 100
Remainder = 10
9. Answer
the following questions.
a) Write
a program in QBASIC that will asks the user to input length, breadth and height
of a room then use SUB procedure calculate its volume and FUNCTION procedure to
calculate its area of four walls.
DECLARE SUB
VOL(L,B,H)
DECLARE
FUNCTION AREA(L,B,H)
CLS
INPUT “Enter
length”; L
INPUT “Enter
breadth”; B
INPUT ”Enter
height”; H
CALL VOL(L,
B, H)
PRINT “Area
of four walls=”; AREA(L, B, H)
END
SUB VOL(L,
B, H)
V=L*B*H
PRINT
“Volume of room”; V
END SUB
FUNCTION
AREA(L, B, H)
AREA=2*H*(L+B)
END FUNCTION
b) A
sequential data file called “Record.dat” has stored data under the field
heading Roll No., Name, Gender, English, Nepali, Maths and Computer. Write a
program to display all the information of those students whose marks in English
is more than 40.
OPEN "Record.dat" FOR INPUT AS
#1
CLS
WHILE NOT EOF (1)
INPUT #1, R, N$,
G$, E, NP, M, C
IF E > 40 THEN
PRINT R, N$, G$, E, NP, M, C
WEND
CLOSE #1
END
10. Write a program in C language that asks any two numbers
and displays the greatest among them.
#include<stdio.h>
#include<conio.h>
int main()
{
int a,b;
printf("Enter any two numbers:\n ");
scanf("%d %d", &a, &b);
if(a>b)
printf("The greatest number is %d", a);
else
printf("The greatest number is %d", b);
return 0;
}
OR
Write
a program in C-Langauge to display the series with their sum. 1,2,3,4….upto 10th terms.
#include
<stdio.h>
int main()
{
int
j, sum = 0;
printf("The first 10 natural number is
:\n");
for (j = 1; j <= 10; j++)
{
sum = sum + j;
printf("%d ",j);
}
printf("\nThe Sum is : %d\n",
sum);
}
***
No comments:
Post a Comment