19
FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL 1) Implement Linear Search to find an item in a list. PROGRAM 1) a) Output: b) K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 1 of 19

Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

  • Upload
    others

  • View
    0

  • Download
    0

Embed Size (px)

Citation preview

Page 1: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

1) Implement Linear Search to find an item in a list.PROGRAM 1)a)

Output:

b)

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 1 of 16

Page 2: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

OUTPUT:

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 2 of 16

Page 3: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

2) Implement binary search to find an item in an ordered list.PROGRAM 2)

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 3 of 16

Page 4: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

3) Implement Sorting AlgorithmsPROGRAM 3 A)a. Bubble sort

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 4 of 16

Page 5: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

b. Insertion sortPROGRAM 3 B)

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 5 of 16

Page 6: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

c. Quick sort

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 6 of 16

Page 7: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

d. Merge Sort

4) Implement use of Sets and various operations on Sets.PROGRAM 4

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 7 of 16

Page 8: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 8 of 16

Page 9: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

5) Implement working of Stacks. (pop method to take the last item added off thestack and a push method to add an item to the stack)

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 9 of 16

Page 10: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

6) Implement Program fora. Infix to Postfix conversionb. Postfix Evaluation

7) Implement the followinga. A queue as a list which you add and delete items from.

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 10 of 16

Page 11: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

b. A circular queue. (The beginning items of the queue can be reused).

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 11 of 16

Page 12: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

8) Implement Linked list and demonstrate the functionality to add and deleteitems in the linked list.

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 12 of 16

Page 13: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

9) Implement Binary Tree and its traversals.

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 13 of 16

Page 14: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

10) Recursive implementation ofa. Factorial

b. Fibonacci

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 14 of 16

Page 15: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

c. Tower of Hanoi

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 15 of 16

Page 16: Prof. Ajay Pashankar · Web view5) Implement working of Stacks. (pop method to take the last item added off the

FYCS SEM II DATA STRUCTURES PRACTICAL MANUAL

K.M. AGRAWAL COLLEGE www.profajaypashankar.com Page 16 of 16