Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add Python bubble sort #303

Closed
wants to merge 2 commits into from
Closed

Add Python bubble sort #303

wants to merge 2 commits into from

Conversation

reidhoch
Copy link

@reidhoch reidhoch commented Oct 5, 2018

Fixes Issue #302 (#302)

For short term contributors: we understand that getting your commits well
defined like we require is a hard task and takes some learning. If you
look to help without wanting to contribute long term there's no need
for you to learn this. Just drop us a message and we'll take care of brushing
up your stuff for merge!

Fixes #{ISSUE_NUMBER}

By submitting this pull request I confirm I've read and complied with the
below declarations.

  • [ x] I have read the Contribution guidelines and I am confident that my PR reflects them.
  • [ x] I have followed the commit guidelines for this project.
  • [ x] My code follows the standard code structure.
  • [ x] This pull request has a descriptive title. For example, {Tag}: Add {Algorithm/DS name} [{Language}], not Update README.md or Added new code.
  • [ x] This pull request will be closed if I fail to update it even once in a continuous time span of 7 days.
  • [ x] This pull request shall only be reviewed and merged once all the checks passes. No maintainer or supporter shall be obliged to review it before this condition is met.
  • [x ] I have mentioned the issue number correctly (with hyperlink) in this pull request description.

After you submit your pull request, DO NOT click the 'Update Branch' button.

seq[i], seq[i+1] = seq[i+1], seq[i]
changed = True
return seq

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The code does not comply to PEP8.

Origin: PEP8Bear, Section: all.autopep8.

The issue can be fixed by applying the following patch:

--- a/tmp/tmpi7_g_6l6/bubble_sort/Python/bubble_sort.py
+++ b/tmp/tmpi7_g_6l6/bubble_sort/Python/bubble_sort.py
@@ -8,6 +8,7 @@
                 changed = True
     return seq
 
+
 if __name__ == "__main__":
     arr = [64, 34, 25, 12, 22, 11, 90]
     bubble_sort(arr)

changed = True
return seq

if __name__ == "__main__":
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

E305 expected 2 blank lines after class or function definition, found 1

Origin: PycodestyleBear (E305), Section: all.autopep8.

@sangamcse sangamcse added invalid This doesn't seem right and removed process/pending_review labels Oct 6, 2018
@sangamcse sangamcse closed this Oct 6, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
invalid This doesn't seem right
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants