Skip to content

Latest commit

 

History

History
29 lines (16 loc) · 756 Bytes

File metadata and controls

29 lines (16 loc) · 756 Bytes

Algorithm

This Algoritm is heapsort which is written in the programming languge of c++ and can be complied using any compiler when u complie the code there will be prompt to:- Enter the array size and depending on that there will be array initalized and then there will be asked to input the array elements so and afetr the array elements are instrted the heap sort function will be called and the array will be sorted aand then the sorted array will be output and then you can see the sorted array using heapsort The sample run is given below:-

 clang++-7 -pthread -std=c++17 -o main main.cpp

 ./main

Size of the arrsy?:

4

Enter array:

34 52 634 463

Sorting...........................................

Sorted array is:

34 52 463 634