Kerala SET Computer Science Paper II 2010 - Part 1

1.       Suppose you are given an array s[1. . n] and a procedure reverse(s, i, j) which reverses the order of elements in s between positions i and j (both inclusive). What does the following sequence do, where 1<k<n:
reverse (s,1,k)
reverse(s, k+1, n);
reverse(s, 1, n);
(A) Rotates s left by k positions
(B) Leaves s unchanged
(C) Reverse all elements of s
(D) None of the above
Answer: A
2.       If 7 bits were used to store a character the percentage reduction of storage will be
(A) 22.5
(B) 2.5
(C) 8
(D) 12.5
Answer: D
3.       The possible output of printf(“%d %d “,p, p+1)if p is a float pointer variable is
(A) 3272 3272
(B) 3272 3276
(C) 3272 3273
(D) 3272 3274
Answer: B
4.       Which of the following UNIX tools receives input only from standard input?
(A) awk
(B) sed
(C) grep
(D) tr
Answer: D
5.       Files that store data in the same format as used in the program are called
(A) Binary files
(B) Source files
(C) Text files
(D) Core
Answer: A
6.       In a UNIX system if 4 people are currently using the vi editor, then the number of corresponding processes will be
(A) 8
(B) 4
(C) 5
(D) 1
Answer: B
7.       When a process makes a system call, its mode changes from
(A) User to kernel
(B) Kernel to user
(C) Unrestricted to restricted
(D) All of the above
Answer: A
8.       The following program
main()
{
if (fork () >0)
sleep (100);
}
Results in the creation of
(A) An orphan process
(B) A zombie process
(C) A process that executes for ever
(D) All of the above
Answer: B
9.       In which section of a process, the information about the arguments to the program are available?
(A) Data
(B) Text
(C) Stack
(D) User-block
Answer: C
10.    Suppose the time to service a page fault is on the average 10 milli seconds, while a memory access takes 1 micro second. Then a 99.99% hit ratio takes an average memory access time of
(A) 1.9999 milliseconds
(B) 1 milli second
(C) 9.999 micro seconds
(D) 1.9999 microseconds
Answer: D

11.    Which of the following system calls transforms an executable binary file into a process?
(A) fork
(B) exec
(C) ioct1
(D) long jmp
Answer: B
12.    R(A,B,C, D) is a relation. Which of the following does not have a lossless-join dependency preserving BCNF decomposition?
(A) A->B, B->CD
(B) A->B, B->C, C->D
(C) AB->C , C->AD
(D) A->BCD
Answer: C
13.    An ordinary calculator treats all operators
(A) To be of equal precedence and associating to the right
(B) To be of equal precedence and associating to the left
(C) To be of unequal precedence and associating to the left
(D) Used in mathematical sense
Answer: A
14.    The principle that a function can always be replaced by its value (irrespective of the context) without changing the meaning is called
(A) Referential transparency
(B) Orthogonality
(C) Context-free
(D) Unbinding
Answer: A
15.    The period of time between an allocation and its subsequent disposal is called
(A) Scope
(B) Dynamic binding
(C) Lifetime
(D) Longevity
Answer: C
16.    Heap allocation is required for languages that
(A) Support recursion
(B) Support dynamic data structures
(C) Use dynamic scope variables
(D) None of the above
Answer: B
17.    A device employing INTR line for device interrupt puts the CALL instruction on the data bus while
(A) INTA is active
(B) HOLD is active
(C) READY is active
(D) None of the above
Answer: A
18.    According to the principle of logic, an implication and its contra positive must be
(A) Both true
(B) Both true or both false
(C) Both false
(D) None of these
Answer: B
19.    Which of the following logical operation resembles an arithmetic multiplication operation?
(A) OR
(B) AND
(C) NOR           
(D) XOR
Answer: B
20.    Consider the following declaration of a two-dimensional array in
char a [100][100];
Assuming that the main memory is byte addressable and that the array is stored starting from memory address 0, the address of a [40][50] is
(A) 4040
(B) 4050
(C) 5040
(D) 5050
Answer: B


Post a Comment

0 Comments