Sunday, September 10, 2017

Kerala PSC HSST Computer Science Previous Questions - Set 3

Answers given at the end.
 
Q1. For some page–replacement algorithms, the page-fault rate may increase as the number of allocated frames increases. This is known as:
(A) Thrashing
(B) Swapping
(C) Belady’s anomaly
(D) Fragmentation

Q2. The Unix inode contains ___________ pointers to data blocks and _________ pointers to indirect blocks.
(A) 10,3
(B) 10,5
(C) 12,3
(D) 15,5





Q3. Which of the following disk scheduling algorithms may result in starvation?
(A) FCFS
(B) Shortest-seek-time-first
(C) SCAN
(D) C-SCAN

Q4. An RPC uses ______________ to execute a routine on a remote system.
(A) FTP
(B) TFTP
(C) TCP
(D) UDP

Q5.  'Location transparency' in distributed systems means that:
(A) Name of the file does not reveal any hint of its physical storage location
(B) Name of the file does not need to be changed when the storage location changes
(C) The storage location can be understood from the name of the file
(D) Name of the file will change if the storage location changes

Q6. The BSD version of UNIX was developed by:
(A) Bell Labs
(B) MIT
(C) University of Berkeley
(D) Sun Microsystems


Q7.  An example of a file system whose contents are not actually stored anywhere, but are computed on demand is:
(A) NTFS
(B) NFS
(C) proc
(D) ext3

Q8. Which among the following is a type of top-down parsing?
(A) Predictive parsing                                   
(B) Shift-reduce parsing
(C) Operator precedence parsing
(D) LR parsing

Q9.  If r and s are regular expressions denoting languages L(r) and L(s), then (r)|(s) is a regular expression denoting:
(A) L(r) U L(s)
(B) L(r) L(s)
(C) {E}
(D)  L(rs)

Q10. What will the following program fragment output?
Integer i=new integer (5);
Integer j=new Integer (5);
If (i==j)System.out.println(“Equal”);
else System.out.println(“Not equal”);
(A) Equal                     
(B) Not Equal
(C) Equal Not equal
(D) The program doesn’t compile= = can’t be used with references


ANSWERS


Q1: (C)
Belady's anomaly is commonly experienced when using the first-in first-out (FIFO) page replacement algorithm.

Q2: (C)
Most modern file systems use 15 pointers consisting of:
  • 12 pointers that directly point to blocks of the file's data (direct pointers)
  • One singly indirect pointer (a pointer that points to a block of pointers that then point to blocks of the file's data)
  • One doubly indirect pointer (a pointer that points to a block of pointers that point to other blocks of pointers that then point to blocks of the file's data)
  • One triply indirect pointer (a pointer that points to a block of pointers that point to other blocks of pointers that point to other blocks of pointers that then point to blocks of the file's data)
Ref:  https://en.wikipedia.org/wiki/Inode_pointer_structure

Q3: (B)

Q4: (D)
Remote Procedure Call (RPC) is a protocol that one program can use to request a service from a program located in another computer on a network without having to understand the network's details.

Q5: (A)

Q6: (C)
Berkeley Software Distribution (BSD) is a Unix operating system derivative developed and distributed by the Computer Systems Research Group (CSRG) of the University of California, Berkeley.

Q7: (C)

Q8: (A)

Q9: (A)

Q10: (B)

No comments:

Post a Comment