sorts: type six algorithms for comparable items - #15246
Conversation
Closing this pull request as invalid@HarshRajSinghania, this pull request is being closed as none of the checkboxes have been marked. It is important that you go through the checklist and mark the ones relevant to this pull request. Please read the Contributing guidelines. If you're facing any problem on how to mark a checkbox, please read the following instructions:
NOTE: Only |
|
ONE ALGORITHM PER PULL REQUEST like it says in:
|
|
You're absolutely right — sorry about that. I missed the explicit one-algorithm-per-PR guidance in the issue, PR template, and CONTRIBUTING.md. I’ve closed out the batch approach and split the work into six separate PRs, one algorithm per PR:
The replacement PRs are based on the current upstream master and each contains only its single algorithm change plus the corresponding mixed-type test. Thanks for calling this out. |
|
The goal is to spread the workload so multiple visitors can learn how to make these changes. If one person does them all, others lose the opportunity to learn by doing. |
Part of #15234
Update six comparison sorts to use bounded
Comparabletype parameters and exercise non-integer comparable inputs.Included algorithms:
cocktail_shaker_sort.pycomb_sort.pycycle_sort.pydouble_sort.pyexchange_sort.pygnome_sort.pyChanges:
Comparableprotocol pattern.Validation performed:
TypeErrorfor mixed incomparable values.