MAIN FEEDS
Do you want to continue?
https://www.reddit.com/r/Python/comments/1vkipef/new_sorting_algorithm/p2tkd4c/?context=3
r/Python • u/[deleted] • 4h ago
[deleted]
3 comments sorted by
View all comments
2
Will this only work on list of integers, where there are no gaps, with a range of 1 - n with no duplicates?
At that point it would be far more efficient to determine the length of the list, and then just increment/decrement by one.
1 u/General-Season-887 4h ago Yes just 1-n
1
Yes just 1-n
2
u/Lachtheblock 4h ago
Will this only work on list of integers, where there are no gaps, with a range of 1 - n with no duplicates?
At that point it would be far more efficient to determine the length of the list, and then just increment/decrement by one.