You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: CONTRIBUTING.md
+4-4
Original file line number
Diff line number
Diff line change
@@ -67,7 +67,7 @@ pre-commit run --all-files --show-diff-on-failure
67
67
We want your work to be readable by others; therefore, we encourage you to note the following:
68
68
69
69
- Please write in Python 3.9+. For instance: `print()` is a function in Python 3 so `print "Hello"` will *not* work but `print("Hello")` will.
70
-
- Please focus hard on naming of functions, classes, and variables. Help your reader by using __descriptive names__ that can help you to remove redundant comments.
70
+
- Please focus hard on the naming of functions, classes, and variables. Help your reader by using __descriptive names__ that can help you to remove redundant comments.
71
71
- Single letter variable names are *old school* so please avoid them unless their life only spans a few lines.
72
72
- Expand acronyms because `gcd()` is hard to understand but `greatest_common_divisor()` is not.
73
73
- Please follow the [Python Naming Conventions](https://pep8.org/#prescriptive-naming-conventions) so variable_names and function_names should be lower_case, CONSTANTS in UPPERCASE, ClassNames should be CamelCase, etc.
@@ -102,7 +102,7 @@ We want your work to be readable by others; therefore, we encourage you to note
102
102
103
103
This is too trivial. Comments are expected to be explanatory. For comments, you can write them above, on or below a line of code, as long as you are consistent within the same piece of code.
104
104
105
-
We encourage you to put docstrings inside your functions but please pay attention to indentation of docstrings. The following is a good example:
105
+
We encourage you to put docstrings inside your functions but please pay attention to the indentation of docstrings. The following is a good example:
106
106
107
107
```python
108
108
defsum_ab(a, b):
@@ -160,7 +160,7 @@ We want your work to be readable by others; therefore, we encourage you to note
160
160
-[__List comprehensions and generators__](https://docs.python.org/3/tutorial/datastructures.html#list-comprehensions) are preferred over the use of `lambda`, `map`, `filter`, `reduce` but the important thing is to demonstrate the power of Python in code that is easy to read and maintain.
161
161
162
162
- Avoid importing external libraries for basic algorithms. Only use those libraries for complicated algorithms.
163
-
- If you need a thirdparty module that is not in the file __requirements.txt__, please add it to that file as part of your submission.
163
+
- If you need a third-party module that is not in the file __requirements.txt__, please add it to that file as part of your submission.
164
164
165
165
#### Other Requirements for Submissions
166
166
- If you are submitting code in the `project_euler/` directory, please also read [the dedicated Guideline](https://github.com/TheAlgorithms/Python/blob/master/project_euler/README.md) before contributing to our Project Euler library.
@@ -172,7 +172,7 @@ We want your work to be readable by others; therefore, we encourage you to note
172
172
- If you have modified/added documentation work, ensure your language is concise and contains no grammar errors.
173
173
- Do not update the README.md or DIRECTORY.md file which will be periodically autogenerated by our Travis CI processes.
174
174
- Add a corresponding explanation to [Algorithms-Explanation](https://github.com/TheAlgorithms/Algorithms-Explanation) (Optional but recommended).
175
-
- All submissions will be tested with [__mypy__](http://www.mypy-lang.org) so we encourage to add [__Python type hints__](https://docs.python.org/3/library/typing.html) where it makes sense to do so.
175
+
- All submissions will be tested with [__mypy__](http://www.mypy-lang.org) so we encourage you to add [__Python type hints__](https://docs.python.org/3/library/typing.html) where it makes sense to do so.
176
176
177
177
- Most importantly,
178
178
-__Be consistent in the use of these guidelines when submitting.__
0 commit comments