Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Create Cycle sort algorithm #404

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
larymak merged 3 commits into larymak:main from KavinduDr:main
Jan 16, 2025
Merged

Create Cycle sort algorithm #404

larymak merged 3 commits into larymak:main from KavinduDr:main
Jan 16, 2025

Conversation

Copy link
Contributor

@KavinduDr KavinduDr commented Jan 10, 2025

No description provided.

Copy link

Hi @KavinduDr! 👋

Thank you for submitting a pull request! We appreciate your contribution and will review your changes as soon as possible.

Copy link
Owner

larymak commented Jan 14, 2025

Attach a README file with the explanation below or a modified one.

This pull request introduces a new implementation of the Cycle Sort algorithm in the Data Structures and Algorithms/Sorting Algorithms/Cycle_Sort.py file. The new function sorts a list of integers and counts the number of writes performed during the sorting process.

Key changes include:

  • Added the cycle_sort function to implement the Cycle Sort algorithm, which sorts a list of integers and returns the number of writes performed.
  • Included a main section to demonstrate the usage of the cycle_sort function, which prints the list before and after sorting, as well as the number of writes.

@larymak larymak merged commit 5033d88 into larymak:main Jan 16, 2025
1 check passed
Copy link

[Create Cycle_Sort.py]
[Update Cycle_Sort.py]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Reviewers
No reviews
Assignees
No one assigned
Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

AltStyle によって変換されたページ (->オリジナル) /