Mumbai University Question Papers Data Structures and Files June 2009

Mumbai University Question Papers

 III Sem CSE – Examination June 2009

Data Structures and Files

N.B.: (1) Question No.1 is compulsory.

(2) Solve any four questions from Question 2 to Question 7.

(3) Use diagrams where necessary.

(4) Figures in right indicate full marks.

1. (a) Explain ADT . List the linear and non linear data structures with their applications.

(b) Write a program in java to create a text file “InputData” to store the data of students as student_id, name and score in percentage. Store the data in sorted order of their descending scores in file named Merit List. Display this data in tabular manner.

2. (a). Write a Java program to classify consonants and vowels from the input data given character by character by storing them in two stacks implemented in the single array. List the characters as consonants and vowels.

(b) Explain priority queue and types of priority queue with application. Give class design for priority queue in Java using linked list with the insert and delete methods.

3. (a) ExplaiI\ Huffman Coding with example. Write a Java program to create the binary tree using Huffman coding for the given characters and their frequencies. Print the Huffman code for each character.

(b) Show with example how graphs are represented in computer memory.

4. (a) Write a Java program to implement circular queue using linked list.

(b) Explain the Recursion. Design recursive Java methods DFS and BFS on graph.

5. (a) Show the formationsteps ofAVLtree for the following elements. Show the rotations.

21,34,5, 70, 18,55,65, 75,85,46,36,26, 16,6

(b) Write a Java program to implement doubly linked list with methods insert, delete and search.

6. (a) Show hash table entries for the given dataset using Linear probing, quadratic probing and double hashing 12, 45, 67, 88, 27, 78, 20, 62, 36, 55

(b) Write the program in Java to perform quick sort. Show the steps with example.

7. (a) Write a Java program to implementbinary search on sorted set of integers.

(b) Write the notes on :-

(i) inorder, preorder and postorder travelsal of tree

(ii) Infix, prefix and postfix expression.

Leave a Comment