Skip to content

Added Josephus Problem in Every Language Article #331

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 10 commits into from
Oct 7, 2020

Conversation

AakashBelide
Copy link
Contributor

@AakashBelide AakashBelide commented Oct 3, 2020

This is in reference to the enhancement for PR in TheRenegadeCoder/sample-programs#1933

This is in reference to the enhancement for PR #1933 in TheRenegadeCoder/sample-programs
Copy link
Member

@jrg94 jrg94 left a comment

Choose a reason for hiding this comment

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

Overall, really nice work! Just a couple minor changes.

@jrg94 jrg94 self-assigned this Oct 6, 2020
@jrg94 jrg94 added the project Project documentation label Oct 6, 2020
@jrg94 jrg94 changed the title Added Josephus Problem article index.md Added Josephus Problem in Every Language Article Oct 6, 2020
Copy link
Member

@jrg94 jrg94 left a comment

Choose a reason for hiding this comment

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

Awesome! I think we can update the dates and we'll be good to go.

@jrg94
Copy link
Member

jrg94 commented Oct 6, 2020

Actually, when you say "index", do you mean starting from 1 or starting from 0? That should probably be documented in here.

AakashBelide and others added 2 commits October 6, 2020 22:17
Updated date

Co-authored-by: Jeremy Grifski <[email protected]>
Updated date

Co-authored-by: Jeremy Grifski <[email protected]>
@AakashBelide
Copy link
Contributor Author

Actually, when you say "index", do you mean starting from 1 or starting from 0? That should probably be documented in here.

It's starting from 0. Here is a demonstartion of how it works:
(Input: 5(total number of people in circle, 2 (number of people to skip -1)
Output: (Number of people in the circle currently, number of people to skip, index of the person to be killed or removed)
[1, 2, 3, 4, 5] 1 0
[1, 3, 4, 5] 1 1
[1, 3, 5] 1 2
[3, 5] 1 0
3
Hence, the 3rd person remains alive at the end.
Should I add this as an example and mention it in the description of index.md?

@jrg94
Copy link
Member

jrg94 commented Oct 6, 2020

Is there any way you could add this example to the description? I think it would help a lot!

@AakashBelide
Copy link
Contributor Author

Is there any way you could add this example to the description? I think it would help a lot!

Shall I add it as an example in the description or shall I make a new example sub heading and add under it?

@jrg94
Copy link
Member

jrg94 commented Oct 6, 2020

Good question! I think we usually put examples as a sub heading under Description. See Bubble Sort: https://sample-programs.therenegadecoder.com/projects/bubble-sort/

@AakashBelide
Copy link
Contributor Author

Good question! I think we usually put examples as a sub heading under Description. See Bubble Sort: https://sample-programs.therenegadecoder.com/projects/bubble-sort/

I have added an example. Kindly check it and let me know if there are any more changes to be made.

Copy link
Member

@jrg94 jrg94 left a comment

Choose a reason for hiding this comment

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

Looks great! Just a quick fix and we're ready to go

@AakashBelide
Copy link
Contributor Author

Looks great! Just a quick fix and we're ready to go

Great!!

@jrg94 jrg94 merged commit a7ab2d9 into TheRenegadeCoder:master Oct 7, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
project Project documentation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants