UGC NET CS Jul 2018

UGC NET JRF Computer Science · 2018 · with answers and explanations

questions
10
Total marks
20
Duration
180 minutes
Negative marking
No

Subjects: Computer Science

Question 1

Computer Science · 2 marks

At a particular time of computation, the value of a counting semaphore is 10. Then 12 P operations and x V operations were performed on this semaphore. If the final value of semaphore is 7, x will be:

  1. B.9
  2. C.10
  3. D.11
  4. A.8

Correct answer: B

Explanation: Semaphore value: 10 - 12 + x = 7, so x = 9.

Question 2

Computer Science · 2 marks

The period of a signal is 100 ms. Its frequency is

  1. A.1003 Hertz
  2. B.10^-2 KHz
  3. C.10^-2 KHz
  4. D.10^5 Hertz

Correct answer: C

Explanation: Frequency = 1/period = 1/0.1s = 10 Hz = 0.01 KHz = 10^-2 KHz.

Question 3

Computer Science · 2 marks

The dotted-decimal notation of the following IPV4 address in binary notation is: 10000001 00001011 00001011 11101111

  1. C.129.11.11.239
  2. A.111.56.45.239
  3. B.129.11.10.238
  4. D.111.56.11.239

Correct answer: C

Explanation: 10000001=129, 00001011=11, 00001011=11, 11101111=239. So 129.11.11.239.

Question 4

Computer Science · 2 marks

In a paged memory, the page hit ratio is 0.40. The time required to access a page in secondary memory is equal to 120 ns. The time required to access a page in primary memory is 15 ns. The average time required to access a page is

  1. A.105 ns
  2. B.68 ns
  3. C.75 ns
  4. D.78 ns

Correct answer: D

Explanation: Average time = hit_ratio * primary_time + (1-hit_ratio) * secondary_time = 0.40*15 + 0.60*120 = 6 + 72 = 78 ns.

Question 5

Computer Science · 2 marks

Consider a virtual page reference string 1, 2, 3, 2, 4, 2, 5, 2, 3, 4. Suppose LRU page replacement algorithm is implemented with 3 page frames in main memory. Then the number of page faults is

  1. A.5
  2. B.7
  3. C.9
  4. D.10

Correct answer: B

Explanation: Tracing LRU with 3 frames: faults at references 1,2,3,4,5,3,4 = 7 page faults.

Question 6

Computer Science · 2 marks

Page information in memory is also called Page Table. The essential contents in each entry of a page table is/are

  1. B.Virtual Page number
  2. C.Page Frame number
  3. D.Both virtual page number and Page Frame Number
  4. A.Page Access information

Correct answer: D

Explanation: A page table entry essentially maps a virtual page number to a physical page frame number.

Question 7

Computer Science · 2 marks

Which of the following statements are true? (a) External Fragmentation exists when there is enough total memory space to satisfy a request but the available space is not contiguous. (b) Memory Fragmentation can be internal as well as external. (c) One solution to external Fragmentation is compaction.

  1. A.(a) and (b) only
  2. B.(a) and (c) only
  3. C.(b) and (c) only
  4. D.(a), (b) and (c)

Correct answer: C

Explanation: Statement (a) as written says space IS contiguous which is wrong (should be not contiguous). Statements (b) and (c) are correct.

Question 8

Computer Science · 2 marks

Consider a Boolean function of n variables. The order of an algorithm that determines whether the Boolean function produces an output 1 is

  1. C.Quadratic
  2. A.Logarithmic
  3. B.Linear
  4. D.Exponential

Correct answer: D

Explanation: To determine satisfiability of a Boolean function of n variables requires checking up to 2^n assignments in the worst case (Boolean SAT is NP-complete).

Question 9

Computer Science · 2 marks

In C++, polymorphism requires:

  1. A.Inheritance only
  2. B.Virtual functions only
  3. C.References only
  4. D.Inheritance, Virtual functions and references (or pointers)

Correct answer: D

Explanation: Runtime polymorphism in C++ requires inheritance (base-derived relationship), virtual functions (dynamic dispatch), and base class pointers/references.

Question 10

Computer Science · 2 marks

If a function is friend of a class, which one of the following is wrong?

  1. A.A function can only be declared a friend by a class itself
  2. B.Friend functions are not members of a class, they are associated with it
  3. C.Friend functions are members of a class
  4. D.It can have access to all members of the class, even private ones

Correct answer: C

Explanation: Friend functions are NOT members of the class. They have access to private members but are declared outside the class scope.

View all papers — UGC NET JRF Computer Science

Practice this paper with a timer

Attempt it online, get scored instantly, and see which subjects are costing you marks.

Start practising free