Top MCQs on Data Structures in DSA with Answers (original) (raw)

Consider a source with symbols A, B, C, D with probabilities 1/2, 1/4, 1/8, 1/8 respectively. What is the average number of bits per symbol for the Huffman code generated from above information ?

If h is chosen from a universal collection of hash functions and is used to hash n keys into a table of size m, where n ≤ m, the expected number of collisions involving a particular key x is less than _______.

Below are the few steps given for scan-converting a circle using Bresenham’s Algorithm. Which of the given steps is not correct ?

Consider a line AB with A = (0, 0) and B = (8, 4). Apply a simple DDA algorithm and compute the first four plots on this line.

The minimum number of scalar multiplication required, for parenthesization of a matrix-chain product whose sequence of dimensions for four matrices is <5, 10, 3, 12, 5> is

Consider the following AO graph:56Which is the best node to expand next by AO* algorithm?

A t-error correcting q-nary linear code must satisfy:65Where M is the number of code words and X is

Consider the following statements: S1: A queue can be implemented using two stacks. S2: A stack can be implemented using two queues. Which of the following is correct?

Given the following prefix expression: * + 3 + 3 ↑ 3 + 3 3 3 What is the value of the prefix expression ?

In how many ways can the string A ∩ B – A ∩ B – A be fully parenthesized to yield an infix expression?

There are 39 questions to complete.

Take a part in the ongoing discussion