-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
Java implementation for Josephus Problem added. #1410
Conversation
Why did you close #1408? You were supposed to make changes in that only. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Indentation still doesn't seem to be fixed.
I have changed the indentation manually from 8 spaces tab to 4 spaces, what else indentation issue is with that I am not getting it. I closed #1408 because it would have made it two commits. |
There is still tab indentation in the code. You have to use 4-space indentation in place of 1 tab, 8 space indentation for 2 tabs and so on... |
I have used same indentation scheme 4-space indentation in place of 1 tab, 8 space in place of 2 tabs and even checked #1398 PR also, it is also using the same indentation scheme. Even I have checked it on GitHub editor also it is 4 space only. Even I copied the code from "Files changed" from the patch #1410 in vim editor their also the count is 4, 8 and so on. @marwahmanbir please can you be more specific as I'm not able to figure out what point I'm missing. |
{ | ||
public static int Josephus(int n, int m) { | ||
// base case when only 1 person left return 0 assuming people numbered from 0 to n -1 | ||
if (n == 1) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In above few lines the indentation is perfect but from this line onwards there is tab indentation (where 1 tab equivalent to ~ 8 spaces).
You have to convert the whole program to incorporate space indentation instead of tabs.
Implemented Space indentation using git editor.
…into Josephus_Problem
…o_Ds_Notes into Josephus_Problem
Please check the last commit I've understood my mistake and updated it accordingly. |
@marwahmanbir please review this PR as I want to contribute further. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good work.
Fixes #1407
Checklist:
Changes proposed in this pull request:
Languages Used:
Files Added:
Thanks!