SEE Examination 2068
Computer Science
Group “A”
Computer Fundamental [22 marks]
1. Answer the following questions. (2x5=10)
a. Define LAN topology and write any two types of LAN topology.
Ans: The arrangement or connection pattern of computers or nodes and other devices of the network is known as LAN topology.
Any two types of LAN topology are
· Bus topology
Ans: The four services of internet are
· E-mail (Electronic mail)
Ans: The two ad advantages of multimedia in education field are listed below:
· It makes teaching/learning easier in classroom.
Ans: The two software security measures are:
· Backup
Ans: The four symptoms that show, computer is infected by computer virus are listed below:
· Program takes long time to load.
ii. (173)8 into binary
Soln:
Octal 1 7 3
Therefore: (173)8 = (1111011)2
b. Binary calculation. (1x2=2)
i. 111 x11
Soln:
1 1 1
x 1 1
+ 1 1 1 x
1 0 1 0 1
:. 111x11=10101
ii.1010-10+11
Soln:
1 0 1 0
+ 1 1
1 0 1 1
:. 1010-10+11=1011
3. Match the following. (0.5x4=2)
Group A Group B
a. Microwave Multimedia
b. Volt guard Protocol
c. Sound card Unguided media
d. TCP/IP Power protection devices
Guided media
Answers
Group A Group B
a. Microwave Unguided media
b. Volt guard Power protection devices
c. Sound card Multimedia
d. TCP/IP Protocol
4. Select the best answers. (0.5x4=2)
a. Which of the following is not a protocol?
i. POP ii. TCP/IP iii. NOS iv. FTP
b. Which device protects hardware?
i. UPS ii. MODEM iii. Gateway iv. All of the above
c. In which communication media data transfer high?
i. Twisted pair ii. Co-axial cable iii. Fiber optics iv. Microwave
d. Which computer virus damages the master boot record?
i. Macro virus ii. File virus iii. New folder virus iv. Boot sector virus
5. Write the appropriate technical terms. (0.5x4=2)
a. The device used to connect PC with telephone line. MODEM
6. Match the following. (0.5x4=2)
Group B-Database (10 marks)
7. Answer the following questions. (2x3=6)
a. What is database?
Ans: The organized collection of related data in a systemic manner is called a database.
b. What is data sorting?
Ans: Data sorting means grouping all the records in a table either in ascending or descending order based on a key field of the record.
c. What is a form?
Ans: Form is an object of MS-Access which provides a user friendly interface to enter, edit, update and delete data in a table or multiple linked tables.
8. Select the best answers. (0.5x4=2)
a. ………………. Is not a data type of MS-Access.
i. Number ii. Text iii. Memo iv. Form
b. Primary key does not accept ……….
i. Text ii. Number iii. Null value iv. None of the above
c. ……………….. object of access is used to print formatted data.
i. Query ii. Form iii. Report iv. Table
d. In MS-Access data are stored in ………………
i. Form ii. Query iii. Table iv. All of the above
9. Match the following. (0.5x4=2)
Group A Group B
a. Indexing Limits the value
Answers
Group A Group B
a. Indexing Search fast
Group C- Programming (18 marks)
10. Answer the following questions. (2x5=10)a. What is loop?
Ans: Loop means executing a statement or group of statements a certain number of times depending upon the condition.
b. List any two data types supported by ‘C’ language.
Ans: Any two data types supported by ‘C’ language are:
· char
i. EOF It checks whether the record in the file has end or not.
11. Re-write the given program after correcting the bugs. (0.5x4=2)
CREATE FUNCTION Square(A)
Rem to print square of a number
CLS
Get “a number”; A
CALL square(A)
END
FUNCTION square(A)
Ans=A^2
Square=Ans
END Square(A)
Debugged Program
DECLARE FUNCTION Square(A)
Rem to print square of a number
CLS
INPUT “Enter a number”; A
PRINT square(A)
END
FUNCTION square(A)
Ans = A^2
Square = Ans
END FUNCTION
12. Write the output of the given program. (2)
DECLARE SUB Series ()
CALL Series
END
SUB Series ()
A=2
B=2
FOR ctr = 1 TO 2
PRINT A; B;
A=A+B
B=A+B
NEXT ctr
END SUB
OUTPUT: 2 2 4 6
13. Analyze the program given below and answer the questions. (1x2=2)
DECLARE FUNCTION count(N$)
INPUT “Enter a word”; N$
C= Count(N$)
PRINT C
END
FUNCTION count(N$)
FOR k=1 TO LEN(n$)
X$=MID$(N$,K,1)
IF UCASE$(X$)=”A” THEN
X=X+1
END IF
NEXT K
Count = X
END FUNCTION
a. List any two library functions used in the above program.
Ans: The two library functions used in the above program are
· UCASE$( )
b. Write the use of variable ‘C’ inline 3 [i.e. C=Count(R$)] given in the above program.
Ans: The use of variable ‘C’ inline 3 [i.e. C=Count(R$)] given in the above program is to call the function and store the value returned by the function count.
14. a. Write a program to calculate the area of four walls using SUB…END SUB. (3)
DECLARE SUB AREA (L, B, H)
CLS
INPUT “ENTER LENGTH”; L
INPUT “ENTER BREADTH”; B
INPUT “ENTER HEIGHT”; H
CALL AREA (L, B, H)
END
SUB AREA (L, B, H)
A = 2 * H * (L + B)
PRINT “AREA OF FOUR WALLS =”; A
END SUB
b. Write a program using FUNCTION…...END FUNCTION to get a word from the user and print it in reverse order. (3)
DECLARE FUNCTION REVERSE$ (S$)
CLS
INPUT "ENTER ANY WORD"; S$
PRINT "REVERSED WORD IS "; REVERSE$(S$)
END
FUNCTION REVERSE$ (S$)
FOR I = LEN(S$) TO 1 STEP -1
B$ = MID$(S$, I, 1)
W$ = W$ + B$
NEXT I
REVERSE$ = W$
END FUNCTION
c. A sequential data file called “student.dat” contains some records under the field’s name, English, Nepali, and Computer. Write a program to add some more records in the same sequential data file. (3)
OPEN “student.dat” FOR APPEND AS #1
DO
CLS
INPUT “ENTER NAME”; N$
INPUT “ENTER MARKS IN ENGLISH”; E
INPUT “ENTER MARKS IN NEPALI”; N
INPUT “ENTER MARKS IN COMPUTER”; C
WRITE #1, N$, E, N, C
INPUT “DO YOU WANT TO CONTINUE? (Y/N)”; CH$
LOOP WHILE UCASE$(CH$) = “Y”
CLOSE #1
END
DECLARE FUNCTION REVERSE$ (S$)
CLS
INPUT "ENTER ANY WORD"; S$
PRINT "REVERSED WORD IS "; REVERSE$(S$)
END
FUNCTION REVERSE$ (S$)
FOR I = LEN(S$) TO 1 STEP -1
B$ = MID$(S$, I, 1)
W$ = W$ + B$
NEXT I
REVERSE$ = W$
END FUNCTION
c. A sequential data file called “student.dat” contains some records under the field’s name, English, Nepali, and Computer. Write a program to add some more records in the same sequential data file. (3)
OPEN “student.dat” FOR APPEND AS #1
DO
CLS
INPUT “ENTER NAME”; N$
INPUT “ENTER MARKS IN ENGLISH”; E
INPUT “ENTER MARKS IN NEPALI”; N
INPUT “ENTER MARKS IN COMPUTER”; C
WRITE #1, N$, E, N, C
INPUT “DO YOU WANT TO CONTINUE? (Y/N)”; CH$
LOOP WHILE UCASE$(CH$) = “Y”
CLOSE #1
END
Comments
Post a Comment