GoalScope — permutations (Qwen2.5-Coder-32B-Instruct) — hover a token to see the patched verbalization
<code>↵ def permutations(nums):↵ """Generate all permutations of a list."""↵ if len(nums) == 0:↵ return []↵ if len(nums) == 1:↵ return [nums]↵ result = []↵ for i in range(len(nums)):↵ current = nums[i]↵ remaining = nums[:i] + nums[i+1:]↵ for p in permutations(remaining):↵ result.append([current] + p)↵ return result</code>