Skip to content
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

feat: add next permutation problem #720

Merged

Conversation

jafar75
Copy link
Contributor

@jafar75 jafar75 commented May 3, 2024

A practice to find lexicographically next greater permutation of the given array of integers.

  • If there does not exist any greater permutation, then print the lexicographically smallest permutation of the given array.
  • The implementation below, finds the next permutation in linear time and constant memory and returns in place.

@codecov-commenter
Copy link

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 87.39%. Comparing base (833a3e5) to head (93c207e).

Additional details and impacted files
@@            Coverage Diff             @@
##           master     #720      +/-   ##
==========================================
+ Coverage   87.36%   87.39%   +0.03%     
==========================================
  Files         200      201       +1     
  Lines        5317     5333      +16     
==========================================
+ Hits         4645     4661      +16     
  Misses        533      533              
  Partials      139      139              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@jafar75
Copy link
Contributor Author

jafar75 commented May 3, 2024

sounds odd! one of the tests is failing that haven't changed since years ago

@raklaptudirm raklaptudirm merged commit 2354582 into TheAlgorithms:master May 9, 2024
4 of 5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants