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

contribution guidelines checks #1787

Merged
merged 16 commits into from Mar 4, 2020
Merged

contribution guidelines checks #1787

merged 16 commits into from Mar 4, 2020

Conversation

@matkosoric
Copy link
Contributor

matkosoric commented Mar 3, 2020

Describe your change:

documentation change - spelling

Checklist:

  • I have read CONTRIBUTING.md.
  • This pull request is all my own work -- I have not plagiarized.
  • I know that pull requests will not be merged if they fail the automated tests.
  • This PR only changes one algorithm file. To ease review, please open separate PRs for separate algorithms.
  • All new Python files are placed inside an existing directory.
  • All filenames are in all lowercase characters with no spaces or dashes.
  • All functions and variable names follow Python naming conventions.
  • All function parameters and return values are annotated with Python type hints.
  • All functions have doctests that pass the automated testing.
  • All new algorithms have a URL in its comments that points to Wikipedia or other similar explanation.
  • If this pull request resolves one or more open issues then the commit message contains Fixes: #{$ISSUE_NO}.
predictive analysis. The idea is pretty simple: we have a dataset and we have
features associated with it. Features should be chosen very cautiously
as they determine how much our model will be able to make future predictions.
We try to set these features weights, over many iterations, so that they best

This comment has been minimized.

Copy link
@cclauss

cclauss Mar 3, 2020

Member

We try to set the weight of these features...

@cclauss
cclauss approved these changes Mar 3, 2020
swapped = False
i = 0
# Update the gap value for a next comb
gap = int(gap / shrink_factor)

This comment has been minimized.

Copy link
@cclauss

cclauss Mar 3, 2020

Member

gap //= shrink_factor # will give us integer division

This comment has been minimized.

Copy link
@matkosoric

matkosoric Mar 3, 2020

Author Contributor

does not work, return type is still float

This comment has been minimized.

Copy link
@cclauss

cclauss Mar 4, 2020

Member

You are correct. Sorry for the mistake.

>>> 35.2 / 7
5.028571428571429
>>> 35.2 // 7
5.0
@@ -1,8 +1,13 @@
"""
This is pure python implementation of comb sort algorithm.

This comment has been minimized.

Copy link
@cclauss

cclauss Mar 3, 2020

Member

python --> Python # it is a brand name, not a snake.

This comment has been minimized.

Copy link
@TheSuperNoob

TheSuperNoob Mar 3, 2020

Contributor

Is it even needed to say its implemented in Python given that this entire repository should just be python algorithms?

This comment has been minimized.

Copy link
@cclauss

cclauss Mar 3, 2020

Member

I think it is fine to write that this is a Python implementation.
The code might be copied elsewhere outside this repo.

matkosoric added 4 commits Mar 3, 2020
Examples:
>>> comb_sort([0, 5, 3, 2, 2])
[0, 2, 2, 3, 5]
>>> comb_sort([])
[]
>>> comb_sort([-2, -5, -45])
[-45, -5, -2]
>>> comb_sort([99,45,-7,8,2,0,-15,3])

This comment has been minimized.

Copy link
@cclauss

cclauss Mar 4, 2020

Member

Comma space please.

@matkosoric matkosoric changed the title spelling corrections contribution guidelines checks Mar 4, 2020
matkosoric and others added 3 commits Mar 4, 2020
@poyea
poyea approved these changes Mar 4, 2020
Copy link
Member

poyea left a comment

Thank you for your pull request!🤩

@cclauss cclauss merged commit 7f04e5c into TheAlgorithms:master Mar 4, 2020
3 checks passed
3 checks passed
codespell
Details
LGTM analysis: Python No new or fixed alerts
Details
Travis CI - Pull Request Build Passed
Details
@cclauss
Copy link
Member

cclauss commented Mar 4, 2020

NICE!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

4 participants
You can’t perform that action at this time.