Sitelet https://github.com/TheRenegadeCoder/sample-programs/pull/1933
Skip to content

Added Josephus Problem in Python - #1933

Closed
AakashBelide wants to merge 1 commit into
TheRenegadeCoder:masterfrom
AakashBelide:master
Closed

AakashBelide wants to merge 1 commit into
TheRenegadeCoder:masterfrom
AakashBelide:master

Conversation

@AakashBelide

@AakashBelide AakashBelide commented Oct 1, 2020 •

Copy link
Copy Markdown

I have added Josephus problem solution using recursion in Python

Congrats on taking the first step to contributing to the Sample Programs repository maintained by The Renegade Coder!
For simplicity, please make sure that your pull request includes one and only one contribution.

Complete the Applicable Sections Below

Find which section best describes your pull request and make sure you fill it out. To start, let us know which issue you've fixed.

  • I fixed #your-issue-number-here

Code Snippets

  • I named the pull request using Added/Updated <Sample Program> in <Language> format
  • I created/updated the language README
    • I added the sample program name to the README
    • I added fun facts (i.e. debut, developer, typing, etc.)
    • I added reference link(s) to the README
    • I added solution citations when necessary (see plagiarism)

Testing

  • I named the pull request using Added/Updated <Language>/<Project> Testing format
  • I followed the testinfo template, if applicable

Notes

Feel free to describe what you added or updated.

Josephus problem solution using recursion

@jrg94 jrg94 left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

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

Very cool idea! Any chance we could get this documented here first: https://sample-programs.therenegadecoder.com/projects/

@jrg94 jrg94 changed the title Added Josephus Problem solution using recursion in Python Added Josephus Problem in Python Oct 2, 2020
@jrg94 jrg94 self-assigned this Oct 2, 2020
@jrg94 jrg94 added the enhancement Any code that improves the repo label Oct 2, 2020
@jrg94 jrg94 added this to the 500 Code Snippets milestone Oct 2, 2020
@jrg94 jrg94 added the needs docs New code that isn't documented here: https://sampleprograms.io/projects/ label Oct 2, 2020
@AakashBelide

Copy link
Copy Markdown
Author

@jrg94 absolutely sure! Could you please tell what's the procedure to get this documented? Thanks in advance

@jrg94

jrg94 commented Oct 2, 2020

Copy link
Copy Markdown
Member

@AakashBelide

Copy link
Copy Markdown
Author

As guided, I have made a new folder with an index.md file using the provided template. Kindly check PR #331 in TheRenegadeCoder /sample-programs-website. If there is anything else to be changed, kindly let me know.

@jrg94

jrg94 commented Oct 6, 2020

Copy link
Copy Markdown
Member

Finally got around to it! When it does get approved, we'll ask you to add testing to this pull request.

@AakashBelide

Copy link
Copy Markdown
Author

Great! I have made the suggested changes. Thank you for all the help!

@jrg94

jrg94 commented Oct 7, 2020

Copy link
Copy Markdown
Member

Okay! Now that the article is in place. Any chance we could start writing tests?

@AakashBelide

Copy link
Copy Markdown
Author

Okay! Now that the article is in place. Any chance we could start writing tests?

Yeah sure. I haven't written code for testing anytime so far, so can you just guide me about it? I just checked a few files in the test folder in the sample-programs repo.

@jrg94

jrg94 commented Oct 7, 2020 •

Copy link
Copy Markdown
Member

Yeah it's a little complicated. Basically, you would need to add a new instance for the test:

Then, you'll need to create a file here: https://github.com/TheRenegadeCoder/sample-programs/tree/master/test/projects. You can use the other test files as an example. A good example might be Binary Search: https://github.com/TheRenegadeCoder/sample-programs/blob/master/test/projects/test_binary_search.py

@AakashBelide

Copy link
Copy Markdown
Author

Okay. I will update you ones it's done. Thank you

@jrg94 jrg94 added the needs tests New language or project that isn't tested label Oct 26, 2020
@jrg94 jrg94 closed this Oct 26, 2020
@jrg94 jrg94 reopened this Oct 26, 2020
@jrg94

jrg94 commented Oct 26, 2020

Copy link
Copy Markdown
Member

If you're still interested in adding this program, we'll need to add some testing. Thanks for putting the docs together.

@jrg94 jrg94 added josephus problem See: https://sampleprograms.io/projects/josephus-problem/ and removed needs docs New code that isn't documented here: https://sampleprograms.io/projects/ labels Oct 26, 2020
@AakashBelide

Copy link
Copy Markdown
Author

If you're still interested in adding this program, we'll need to add some testing. Thanks for putting the docs together.

Yeah sure. I was caught up with some important work so I couldn't do it.

@jrg94

jrg94 commented Oct 29, 2020

Copy link
Copy Markdown
Member

No worries! Just wanted to let you know that's why this solution is pending.

@jrg94 jrg94 closed this May 7, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement Any code that improves the repo josephus problem See: https://sampleprograms.io/projects/josephus-problem/ needs tests New language or project that isn't tested

Projects

Archived in project

Development

Successfully merging this pull request may close these issues.

2 participants