LOYOLA COLLEGE (AUTONOMOUS), CHENNAI – 600 034

advertisement
LOYOLA COLLEGE (AUTONOMOUS), CHENNAI – 600 034
M.C.A. DEGREE EXAMINATION – COMPUTER APPLICATION
FIRST SEMESTER – NOVEMBER 2012
CA 1805 – PROGRAMMING AND DATA STRUCTURE THROUGH C++
Date : 03/11/2012
Time : 1:00 - 4:00
Dept. No.
Max. : 100 Marks
PART-A
Answer ALL Questions:
10*2=20
1) Define data encapsulation.
2) State the use of this pointer.
3) Define function. State the use of friend function.
4) What is an exception?
5) Define queue. List it types.
6) Define linked list.
7) What are the constraints of Red Black tree?
8) What are threaded binary trees?
9) Define Graph.
10) What is a minimum spanning tree?
PART-B
Answer ALL Questions:
11.a)Write short notes on token.
(or)
b) Explain the different operators used in C++.
12.a)What is inheritance? Explain the types of inheritance .
(or)
b)What is a file? Explain the file stream classes.
13.a)Define stack. What are the operations performed on stack.
(or)
b) Perform radix sort and selection sort with the given data.
397 , 468,965 , 201, 779,543, 101,645,854, 729
14.a) Explain the conversion of forest into binary tree.
(or)
b)Illustrate AVL rotations due to
i) left to left insertion
ii) right to right insertion
5*8=40
15.a) Explain the different types of graph.
(or)
b)Obtain the minimum spanning tree of the following graph using kruskal’s
algorithm and prim’s algorithm.
V
1
4
V
2
5
2
1
8
2
V
4
3
V
3
4
10
7
V
5
V
6
9
6
V
7
PART-C
Answer any TWO Questions:
2 * 20 = 40
16.a) Discuss in detail the various storage class specifiers(8)
b) Explain various types of constructors.(12)
17.a) Explain error handling mechanism .
b) What is a queue? Explain its types and applications.
18.a)What is hashing? Explain its techniques with necessary examples.(!2)
b) Demonstrate Dijkstra’s algorithm for the following graph.(8)
11
V
1
66
22
V
2
V
3
44
33
55
V
4
22
V
5
22
******
Download