PSC HSST Computer Science Model Questions & Answers : Part 2

Last Updated On: 30/04/2018

51. The ……………….. sort relatively passes through a list to exchange the first element with any element less than it and then repeats with a new first element
(A) selection sort (B) quick sort
(C) insertion sort (D) heap sort
Answer: B

52. Which among the following is the data structure that is used to check balanced parenthesis in an expression
(A) Stack (B) Tree
(C) Queue (D) Array
Answer: A

53. p → q is logically equivalent to
(A) ~q → p (B) ~pνq
(C) ~pΛq (D) ~p → q
Answer: B

54. Which of the following regular expression over {0,1} denotes the set of all strings not containing 100 as substring?
(A) 0*1*01* (B) 0*1010*
(C) 0*(1*0)* (D) 0*(10+1)*
Answer: D

55. Which one of the following is NOT a size metric?
(A) Cyclomatic complexity (B) Function count
(C) LOC (D) Program Length
Answer: A

56. How many times is the symbol ‘&’ printed by the call sample(4)?

void sample(int i){
  if(i>1){
    sample(i/2);
    sample(i/2);
  }
   cout<<"&";
   }

(A) 3 (B) 4
(C) 7 (D) 8
Answer: C

57. The scheduling policy that is most suitable for a time-shared operating system is :
(A) SJF (B) Elevator
(C) Round Robin (D) FCFS
Answer: C

58. If a node in a BST has two children, then its inorder predecessor has
(A) no child (B) no left child
(C) no right child (D) two children
Answer: C

59. The maximum number of processes that may be simultaneously inside the critical section inorder to avoid race condition is
(A) one (B) zero
(C) more than two (D) two
Answer: A

60. The time required by a sector to reach below read/write head is called as ……………….
(A) Seek time (B) Access time
(C) Latency time (D) None
Answer: C

61. Which one of the following TCP/IP protocol is used for transferring e-mail messages from one machine to another?
(A) RPC (B) FTP
(C) SMTP (D) RTP
Answer: C

62. Among the following, which one is used to connect two systems, specifically if the systems use different protocols.
(A) hub (B) bridge
(C) gateway (D) repeater
Answer: C

63. The disadvantage of a pipe is that
(A) It is a one way communication channel
(B) It dies along with the process that created it
(C) It cannot be shared by unrelated processes
(D) All of the above
Answer: D

64. a subschema expresses
(A) the physical view (B) the logical view
(C) the external view (D) all of the above
Answer: C

65. Given that modules X and Y operate on the same input and output data, then the cohesion is
(A) Procedural (B) Communicational
(C) Logical (D) Sequential
Answer: B

66. Which among the following sorting methods is the most suitable one for sorting a list which is almost sorted
(A) Bubble Sort (B) Quick sort
(C) Selection sort (D) Insertion sort
Answer: A

67. ………………… is the scheduler which selects processes from secondary storage for scheduling
(A) Process scheduler (B) Short term scheduler
(C) Medium term scheduler (D) Long term scheduler
Answer: C

68. Among the following which one is NOT a weighted code?
(A) Binary number system (B) Excess 3 code
(C) Decimal number system (D) None of these
Answer: B

69. LDAP stands for
(A) Large Directory Access Protocol
(B) Lightweight Directory Access Protocol
(C) Large Data Access Protocol
(D) Lightweight Data Access Protocol
Answer: B

70. EPROM is erased by using
(A) Ultraviolet rays (B) 24 V electric pulse
(C) 12 V electric pulse (D) infrared rays
Answer: A

71. The language that has recently become the defacto standard for interfacing application programs with relational database system is
(A) 4GL (B) SQL
(C) Dbase (D) Oracle
Answer: B

72. A translator which performs macro expansion is called as ………………..
(A) Micro pre-processor (B) Macro processor
(C) Assembler (D) Macro pre-processor
Answer: D

73. The term ‘page traffic’ refers to
(A) the movement of pages in and out of memory
(B) number of pages of executing programs loaded in memory
(C) number of pages in memory at a given instant
(D) number of pages required to be brought in at a given page request
Answer: A

74. The term ‘page traffic’ refers to
(A) the movement of pages in and out of memory
(B) number of pages of executing programs loaded in memory
(C) number of pages in memory at a given instant
(D) number of pages required to be brought in at a given page request
Answer: A

75. The running time of the following fragment of code is :

for (int i=0;i<20;i++)
for(int j=0;j<N;j++)
for (int k=N-2;k<N+2;k++)
cout<<i<<" "<<j<<endl;

(A) O(N log N) (B) O(log N)
(C) O(N2) (D) O(N)
Answer: D

       
Subscribe
Notify of
5 Comments
Oldest
Newest Most Voted
Inline Feedbacks
View all comments

51. The ……………….. sort relatively passes through a list to exchange the first element with any element less than it and then repeats with a new first element
(A) selection sort (B) quick sort
(C) insertion sort (D) heap sort
Answer: B

The correct answer is Selection Sort. i.e, Option A

Selection sort replaces ith element with ith smallest element (not any element smaller than it)

85. Quick sort algorithm belongs to the ………………… design technique.
(A) Backtracking (B) Dynamic programming
(C) Greedy (D) Divide and Conquer
Answer: C
It is D) Divide and Conquer 🙂

PLEASE give me the logic of qn no56..

23. The device that is used to forward data packets from one network to another is called a …………………
(A) Bridge (B) Hub
(C) Switch (D) Gateway
Answer: C
Correct answer is D(Gateway/Router)

JOIN
5
0
Would love your thoughts, please comment.x
()
x