forked from pclubuiet/Hacktoberfest-2k17
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Adding suraj44 participant details (pclubuiet#32)
* Adding suraj44 participant details * Adding bubblesort in Python
- Loading branch information
Showing
2 changed files
with
21 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
def bubblesort(L): | ||
l = len(L) | ||
swap = 1 | ||
i = 0 | ||
while(swap!= 0): | ||
swap = 0 | ||
for j in range(i,l): | ||
if L[j-1] > L[j]: | ||
L[j],L[j-1] = L[j-1], L[j] | ||
swap+=1 | ||
|
||
i+=1 | ||
return L | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,6 @@ | ||
Name: Suraj Singh | ||
GitHub Username: suraj44 | ||
Degree and Year: 2nd Year, B. Tech | ||
Department: Computer Engineering | ||
|
||
Interests: Machine Learning and Data Science |