Mascot Previous Years Solved Sample Placement Papers
-
A typical modern computer uses:
- a) magnetic cores for secondary storage
- b) LSI chips (Ans)
- c) magnetic tape for primary memory
- d) more than 10,000 vacuum tubes
-
A collection of 8 bits is called:
- a) byte (Ans)
- b) record
- c) word
- d) nibble
-
General-purpose computers are those that can be adopted to countless uses simply by changing their:
- a) output device
- b) input device
- c) processor
- d) program (Ans)
-
The current generation of computers:
- a) second
- b) fifth
- c) fourth (Ans)
- d) third
-
Non-volatility is an important advantage of:
- a) CCDs
- b) magnetic tapes and disks
- c) magnetic bubbles
- d) both b and c (Ans)
-
What is the corresponding postfix expression for the given infix expression? a*(b+c)/d
A) ab*+cd/
B) ab+*cd/
C) abc*+/d
D) abc+*d/ (Ans)
-
What is the corresponding postfix expression for the given infix expression? a+(b*c(d/e^f)*g)*h)
A) ab*cdef/^*g-h+
B) abcdef^/*g*h*+ (Ans)
C) abcd*^ed/g*-h*+
D) abc*de^fg/*-*h+
-
What is the correct postfix expression for the following expression? a+b*(c^d-e)^(f+g*h)-i
A) abc^de-fg+*^*+i
B) abcde^-fg*+*^h*+i
C) abcd^e-fgh*+^*+i (Ans)
D) ab^-dc*+ef^gh*+i
-
Why do we need a binary tree which is height balanced?
- a) to avoid formation of skew trees (Ans)
- b) to save memory
- c) to attain faster memory access
- d) to simplify storing
Explanation: In real-world scenarios, dealing with random values is often not possible. The probability of encountering non-random values (like sequential ones) often leads to skew trees, causing worst-case scenarios. Thus, height balance is maintained by rotations.
-
What is the maximum height of an AVL tree with p nodes?
- a) p
- b) log(p) (Ans)
- c) log(p)/2
- d) p^2
Explanation: The number of nodes in terms of height follows the recurrence relation: N(he) = N(he-1) + 1 + N(he-2). Solving this relation gives N(he) = O(logp) as the worst-case height.
-
To restore the AVL property after inserting an element, do we start at the insertion point and move towards the root of the tree?
- a) true (Ans)
- b) false
Explanation: After insertion, only the path from the insertion point to the root or specific subtrees may become imbalanced in terms of height.
-
Given an empty AVL tree, how would you construct an AVL tree when a set of numbers is given without performing any rotations?
- a) just build the tree with the given input
- b) find the median of the set of elements given, make it the root, and construct the tree (Ans)
- c) use trial and error
- d) use dynamic programming to build the tree
Explanation: Constructing the tree with the median as the root ensures balance without requiring rotations.
-
The memory address of element A[i][j] in row-major order is:
A: loc(A[i][j]) = base(A) + W((i-LB) + n(j-LB))
B: loc(A[i][j]) = base(A) + W(n(j-LB) + (i-LB))
C: loc(A[j][i]) = base(A) + W(n(I-LB) + n(j-LB))
D: loc(A[i][j]) = base(A) + W((I-LB) + n(j-LB))
Ans: B -
The memory address of elements A[i][j] in column-major order is:
A: loc(A[i][j]) = base(A) + W((I-LB) + m(j-LB))
B: loc(A[i][j]) = base(A) + W(m(j-LB) + (i-LB))
C: loc(A[j][i]) = base(A) + W(n(I-LB) + m(j-LB))
D: loc(A[i][j]) = base(A) + W((I-LB) + m(j-LB))
Ans: B -
The base address of an array is the address of:
A: A[1]
B: A[n1]
C: A[0]
D: Both A and B
Ans: C -
Which data structure is used to implement queues, trees, graphs?
A: Stack
B: List
C: Array
D: None
Ans: C -
In which data structure do addition and deletion of elements take place from the same position?
A: Stack
B: List
C: Array
D: Queue
Ans: A