0% found this document useful (0 votes)
6 views

Operating System

Operating system

Uploaded by

ranahmad049
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
6 views

Operating System

Operating system

Uploaded by

ranahmad049
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

FCCU, Computer Science Post Graduate Program

Entrance Exam
Core Computer Science Section (Sample Questions)

1. Which of the following is true about the Big O notation for constant time
complexity?

a) It is denoted as O(1)
b) It is denoted as O(log n)
c) It is denoted as O(n)
d) It is denoted as O(n^2)
Answer: A

2. Which of the following state-space search methods makes the most efficient
use of memory?

A. breadth-first search
B. depth-first search
C. Both are equivalent

Ans: A

3. Consider the following recursive method:

procedure recursiveSum(n):
if n == 1:
return 1
else:
return n + recursiveSum(n - 1)

What does recursiveSum(4) evaluate to?

A. 6
B. 10
C. 15
D. 20
E. 24
Answer: B

4. In a multithreading environment, what is a thread?

A. A process in execution
B. A program in execution
C. A lightweight, independent unit of execution within a process
D. A user interface element

Answer: C

5. In graph theory, what is the purpose of Dijkstra's algorithm?

A. Finding the shortest path in a weighted graph


B. Detecting cycles in a graph
C. Performing topological sorting
D. Traversing a graph in a depth-first manner
Answer: A

6. In how many ways can you arrange the letters of the word "COMPUTER"?
a. 8!
b. 2 x 8
c. 88
d. None of the above
Ans: A

7. What is the primary advantage of dynamic programming in algorithm design?

a) It reduces the time complexity of algorithms


b) It reduces the space complexity of algorithms
c) It breaks down a problem into smaller subproblems and solves each
subproblem only once
d) It is particularly effective for sorting large datasets

Answer: c)

8. In terms of space complexity, which of the following statements is true


for recursive algorithms?

a) Recursive algorithms always have O(1) space complexity


b) Recursive algorithms always have O(n) space complexity
c) Recursive algorithms may have O(1) or O(n) space complexity
d) Recursive algorithms do not use any space

Answer: c)

9. Following sequence of operation is performed on a stack. Push(1), Push(2),


Pop, Push(1), Push(2), Pop, Pop, Pop, Push(2), Pop. The sequences of popped
out values are
A. 2,2,1,2,2
B. 2,2,1,1,2
C. 2,1,2,2,2
D. 2,1,2,2,1
Ans: C

10. Which SQL keyword is used to retrieve only unique values


A. Distinctive
B. Unique
C. Distinct
D. Different
Ans: C

You might also like