-
-
Notifications
You must be signed in to change notification settings - Fork 772
Add contributing guidelines #199
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
Merged
Merged
Changes from all commits
Commits
Show all changes
10 commits
Select commit
Hold shift + click to select a range
8be8a2d
Add contributing guidelines
appgurueu 58d666d
Merge branch 'master' into appgurueu-patch-1
Panquesito7 a83da13
Recommend dashes instead of asterisks for lists
appgurueu f46751e
Elaborate on heading hierarchy
appgurueu 998b385
Merge branch 'master' into appgurueu-patch-1
Panquesito7 d5e4ef9
Elaborate on structure
appgurueu e2a157c
Merge branch 'master' into appgurueu-patch-1
Panquesito7 3f6d6e7
Merge branch 'master' into appgurueu-patch-1
Panquesito7 40e702b
Link to Euclidean Algo as example for good explanation
appgurueu 6ff6cb2
Merge branch 'master' into appgurueu-patch-1
appgurueu File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or 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,64 @@ | ||
# Contributing Guidelines | ||
|
||
## Legal | ||
|
||
Contributions must be all your own work; plagiarism is not allowed. | ||
By submitting a pull request, you agree to license your contribution | ||
under the [license of this repository](https://github.com/TheAlgorithms/Algorithms-Explanation/blob/master/LICENSE.md). | ||
|
||
## Translations | ||
|
||
Translations go in the appropriate folder named by the locale code. | ||
|
||
Do not change the structure or formatting of the original (English) explanation when translating or updating translations. | ||
You may change number formatting to fit the locale | ||
(`42.33` may be formatted as `42,33` in a german translation for instance) | ||
as long as it doesn't create ambiguities | ||
(e.g. `[42,33, 13]` in an array would be disallowed and should either remain `[42.33, 13]` or use a different delimiter `[42,33; 13]`). | ||
|
||
## Writing Explanations | ||
|
||
See the [explanation of the Euclidean Algorithm](en/Basic%20Math/Euclidean%20algorithm.md) | ||
for an example of how a good explanation may look like. | ||
|
||
### Structure | ||
|
||
You should structure your explanations using headings. | ||
The top-level heading should be the name of the algorithm or data structure to be explained | ||
|
||
Subsequent sub-headings *may* be: | ||
|
||
1. Problem solved by the algorithm | ||
2. Design/approach of the algorithm | ||
3. Detailed (yet not too technical) description of the algorithm, usually including (pseudo)-code | ||
4. Analysis (proof of correctness, best/worst/average cases, time & space complexity) | ||
5. Walkthrough(s) of how the algorithm processes example input(s) | ||
6. Application(s) of the algorithm | ||
7. Further resources such as reference implementations, videos or other explanations | ||
|
||
### Capitalization | ||
|
||
- Use *Title Case* for headings. | ||
- Start new sentences with a capital letter. | ||
|
||
### Typographical Conventions | ||
|
||
- Leave a space after punctuation such as `.`, `!`, `?`, `,`, `;` or `:`. | ||
- Add a space before and after `-`. **Do not add a space before punctuation.** | ||
- Add a space before an opening parenthesis `(`. Do not add a space before the closing parenthesis `)`. | ||
- Add spaces around (but not inside) quotes. Use single quotes for quotes within quotes. | ||
|
||
### Markdown Conventions | ||
|
||
[GitHub-flavored Markdown is used](https://github.github.com/gfm/). Explanations should render well when viewed from GitHub. | ||
|
||
- **Do not add redundant formatting.** Formatting should always be meaningful. | ||
If you apply a certain formatting to all elements of a certain kind (e.g. adding emphasis around all headings), you're doing something wrong. | ||
- Use ATX-style "hashtag" headings: `#`, `##`, `###`, `####`, `#####`, `######` rather than Setext-style "underline" headings. | ||
Leave blank lines around headings. The first heading should always be `# Title`. Subheadings must be exactly one level deeper than their parents. | ||
- Indent lists by two blanks. Prefer `-` over `*` for bulleted lists. Enumerate numbered lists correctly, starting at `1`. | ||
- Use fenced code blocks (and specify the correct language) rather than using indented code blocks. | ||
Format code inside fenced code blocks properly (prefer pseudocode over code though). Leave blank lines around fenced code blocks. | ||
- Use named links `[name](link)` rather than relying on automatic link detection or using `<>`-links. | ||
There are rarely good reasons to not give a link a descriptive name. | ||
- Use HTML only if necessary (rarely - if ever - the case). Do not use HTML for unnecessary formatting. |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.