Ask your AI Ask your AI to turn this code into a guided bug-finding exercise.
Claude ChatGPT I am reading "What does a stable sort guarantee when two distinct records compare equal?" on CodeWiki (https://codewiki.com/practice/mcq/foundations/sorting-and-searching/stable-sort-guarantee/).
Context (verbatim from the page):
"""
What does a stable sort guarantee when two distinct records compare equal?
Their relative input order is preserved.
A unique identifier is added automatically.
The records become equal by value.
Their order is identical across all possible inputs.
"""
Introduce three subtle bugs into the example above and let me find them. Reveal each answer only after I have guessed.
Answer in English. Keep code examples in CS foundations. Where you are unsure, say so.