Skip to content

Commit 7146cdf

Browse files
authored
Update heap_sort.py
1 parent 229956d commit 7146cdf

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

Sorting Algorithms/heap_sort.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,8 @@ def heap_sort(arr):
4545
# Taking Elements to be Sorted
4646

4747
data = []
48-
n = int(input("Enter elements to be sorted :"))
48+
n = int(input("Enter total number of elements :"))
49+
print("Enter elements to be sorted ")
4950

5051
for i in range(n):
5152
data.append(int(input()))
@@ -60,7 +61,8 @@ def heap_sort(arr):
6061

6162
'''
6263
INPUT
63-
Enter elements to be sorted : 5
64+
Enter total number of elements :5
65+
Enter elements to be sorted
6466
30
6567
50
6668
10

0 commit comments

Comments
 (0)