MCA 1.2.1 SYSTEMS PROGRAMMING.( Model Paper)
First Question is Compulsory
Answer any four from the remaining
Answer all parts of any Question at one place.
Time: 3 Hrs. Max. Marks: 70
1. Briefly answer the following questions:
a. Define `Abstract Data Type’ ? How are they used in program development?
b. Write the primitive operations of ADT queue.
c. Write the prefix and postfix equivalents to the infix expression A/B+C-D *(E+F).
d. Write the best, worst and average case time complexity estimates of Quick Sort
algorithm.
e. What is an Almost Complete Binary Tree? Write an application that makes use of it.
f. Write the applications of depth first traversal of a graph.
g. When does interpolation search performs better than binary search?
2. a. Assume that each element of an array ‘A’ stored in row-major order occupies four
bytes of memory . If ‘A’ is declared as: int a [10][20][5]. And the address of the
first element of ‘A’ is 2000, find the address of the array element A[5][12][4].
b. Write a C program to evaluate a given postfix expression using stack and explain it
with an example.
3. a. Write a recursive function in C to find the nth Fibonacci number.
b. Write a non – recursive function for the above problem.
c. Compare the efficiencies of the above two functions.
4. a. Compare and contrast the ADTs Queue and Priority Queue.
b. Write a C function to concatenate two singly linked circular list without traversing
either of them and explain it.
5. a. Discuss different ways of representing a binary tree and suggest an application for
each of the representations.
b. Explain how the threads are used to simplify the traversal of a binary tree.
6. a. Construct a binary search tree to accommodate the given list of integers.
47,56,23,17,64,36,29,22
b. Find the in order, preorder and post order sequence of nodes of the above tree.
Explain the process o f deletion of node ‘23’ from the above tree and draw the
resultant tree.
7. Write a C function to arrange the elements of an array in ascending order using
Radix sort algorithm and explain it with a suitable example.
8. a. Discuss the Dijkstra’s algorithm for finding the shortest paths from a source to all
other vertices in a directed graph. What is its time complexity.
0 comments:
Post a Comment