U.G.C. NET Exam. June, 2020 Paper II (COMPUTER SCIENCE & APPLICATIONS)

Total Questions: 100

11. Suppose you are compiling on machine with 1- byte chars, 2-byt shorts, 4-byte ints and 8-byte doubles and with alignment rules that require the address of every primitive date element to be an integer multiple of the element's size. Suppose further that the compiler is not permitted to reorder fields padding is used to ensure alignment. How much space will be consumed by the following array.

Correct Answer: (c) 240 bytes
Solution:

12. Consider the following recursive Java function f that takes two long arguments and returns a float value :


Which of the following real values best approximates the value of f (1, 3)?

Correct Answer: (a) 0.2
Solution:

The function f(1, 3) pass the value to m, n then the value will type cast to float and result = 0.3333 (1/3).
Then it enters into else statement the function result as 0.2 (2/9).
Hence, the correct answer is 0.2.

13. The data node and name node in HADOOP are

Correct Answer: (a) Worker Node and Master Node respectively
Solution:

The main difference between Name Node and data node in HADOOP is that the Name Node is master node in HADDOP distributed file system (HDFS) that manages the file system meta data distributed file system that stores the actual data as instructed by the Name Node.

14. Consider a relational scheme S = (U, V, W, X, Y, Z) on which the following functional dependencies hold.

{U →V, VW→X, Y→W,X→U}
Which are the candidate keys among following options ?

Correct Answer: (d) UYZ, VYZ, X
Solution:

A candidate key is a column or set of columns in a table that can uniquely identify any data base record without referring to any other data.
The following functional dependencies,
U → V, VW → X, Y → W, X →U
S = (U, V, W, X, Y, Z)
Here YZ an independent key, so for every key, the YZ Should their. Hence only option 4 is containing YZ for all keys. Hence the correct answer is UYZ, VYZ, XYZ.

15. Consider a hypothetical machine with 3 pages of physical memory, 5 pages of virtual memory, and <A> as the stream of page references by an application. If P and Q are the number of page faults that the application would incur with FIFO and page replacement algorithms respectively, then (P, Q) = ____ . (Assuming enough space for storing 3 page frames)

Correct Answer: (d) (11, 12)
Solution:

16. Consider a disk system having 60 cylinders, Disk requests are received by a disk drive for cylinders, 10, 22, 20, 2, 40, 6 and 38 in the order. Assuming the disk head is currently at cylinder 20, what is the time taken to satisfy all the requests if it takes milliseconds to move from one cylinder to adjacent one and Shortest Seek Time First (SSTF) algorithm is used ?

Correct Answer: (c) 120 milliseconds
Solution:

17. Suppose you have a Linux file system where the block size is 2K bytes, a disk address is 32 bits and in i-node contains the disk addresses of first 12 direct blocks of file, a single indirect block, and a double indirect block. Approximately, what is the largest file that can be represented by an i-node?

Correct Answer: (b) 513 MBytes
Solution:

18. Consider a single-level page table system, with the page table stored in the memory. If the hit rate to TLB is 80%, and it takes 15 nanoseconds to search the TLB and 150 nanoseconds to access the main memory, then what is the effective memory access time, in nanosecond?

Correct Answer: (b) 195
Solution:

TLB hit ratio = p = 0.8 TLB access time = 15 nano seconds memory access time = m = 150 milliseconds
Formula : EMAT = P×(t+m) + (1–p) ×(t+m+n) EMAT = 0.8×(15 + 150) + (1 – 0.8) × (15 + 150 + 150) EMAT = 195 milliseconds.

19. Which of the following UML diagrams has static view ?

Correct Answer: (b) Use-Case diagram
Solution:

A use case diagram only depicts the system's features while a dynamic model view depicts all functions and behaviour.
• A use case diagram in used to represent the dynamic behaviour of a system. It encapsulates the system's functionality by incorporating used cases, actors and their relationships.

20. Modifying the software by restructuring is called

Correct Answer: (c) Perfective maintenance
Solution:

Corrective, adaptive, perfective and preventive maintenance are the four forms of maintenance.
• Corrective maintenance focuses on resolving issues that arises when the programme is in operation.
• Adaptive maintenance is concerned with the changes made to the software in order to make it adaptable to new. Environments such a running it on a new operating system.
• The term "perfective maintenance" refers to the change in the software that occur as a result of adding new features.
• Preventive maintenance entails making adjustments to avoid mistakes from occurring