-
Notifications
You must be signed in to change notification settings - Fork 962
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
Conversation
Hi @KavinduDr! 👋
Thank you for submitting a pull request! We appreciate your contribution and will review your changes as soon as possible.
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.
maihengxing999
commented
Jan 19, 2025
[Create Cycle_Sort.py]
[Update Cycle_Sort.py]
No description provided.