A directory of Objective Type Questions covering all the Computer Science subjects. Here you can access and discuss Multiple choice questions and answers for various compitative exams and interviews.

31. The average case occurs in the Linear Search Algorithm when :
a. The item to be searched is in some where middle of the Array
b. The item to be searched is not in the array
c. The item to be searched is in the last of the array
d. The item to be searclred is either in the last or not in the array
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).The item to be searched is in some where middle of the Array

32. To determine the efficiency of an algorithm the time factor is measured by
a. Counting micro seconds
b. Counting number of key operations
c. Counting number of statement
d. Counting kilobytes of algorithm
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).Counting number of key operations

33. Which of the following algorithms sort n integers, having the range 0 to (n^2 - 1), in ascending order in O(n) time ?
a. Selection sort
b. Bubble sort
c. Radix sort
d. Insertion sort
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).Radix sort

34. Which of the following is asymptotically smaller?
a. lg(lg*n)
b. lg*(lgn)
c. lg(n!)
d. lg*(n!)
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).lg(lg*n)

35. Code blocks allow many algorithms to be implemented with the following parameters:
a. clarity, elegance, performance
b. clarity, elegance, efficiency
c. elegance, performance, execution
d. execution, clarity, performance
View Answer Report Discuss Too Difficult! Search Google
Answer: (b).clarity, elegance, efficiency

36. Consider f(N) = g(N) + h(N) 
Where function g is a measure of the cost of getting from the start node to the current node N and h is an estimate of additional cost of getting from the current node N to the goal node. Then f(N) = h(N) is used in which one of the following algorithms ? 
a. A* algorithm
b. AO* algorithm
c. Greedy best first search algorithm
d. Iterative A* algorithm
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).Greedy best first search algorithm

37. The reverse polish notation equivalent to the infix expression
((A + B) * C+ D)/(E + F + G)
a. AB + C * D + EF + G + /
b. AB + CD * + EF + G +/
c. AB + C * D + EFG + +/
d. AB + C * D + E + FG +/ 
View Answer Report Discuss Too Difficult! Search Google
Answer: (a).AB + C * D + EF + G + /

38. Superficially the term "object-oriented", means that, we organize software as a
a. collection of continuous objects that incorporates both data structure and behavior
b. collection of discrete objects that incorporates both discrete structure and behavior
c. collection of discrete objects that incorporates both data structure and behavior
d. collection of objects that incorporates both discrete data structure and behavior
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).collection of discrete objects that incorporates both data structure and behavior

39. The number of different spanning trees in complete graph, K4 and bipartite graph, K2,2 have ____ and ____ respectively.
a. 14,14
b. 16,14
c. 16,4
d. 14,4
View Answer Report Discuss Too Difficult! Search Google
Answer: (c).16,4

40. When a method in a subclass has the same name and type signatures as a method in the superclass, then the method in the subclass ______ the method in the superclass.
a. Overloads
b. Friendships
c. Inherits
d. Overrides
View Answer Report Discuss Too Difficult! Search Google
Answer: (d).Overrides

Page 4 of 27