Data Structures and Algorithm # Lab 4
University of Engineering and Technology
Taxila-Electrical Engineering Department
LAB # 4: Array Searching & sorting Methods
Task #1: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using Bubble sort method
Task #2: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using exchange sort method
Task # 3: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using selection sort method
Data Structures and Algorithm # Lab 4
Task # 4: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using insertion sort method
Task # 5: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using Quick sort method
Task # 6: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using Merge sort method
Task # 7: Write a C++ program with following option
a. Accept elements of an array from user
b. Display elements of an array
c. Sort the array using Shell sort method