GoalScope — is_simple_power (Qwen2.5-Coder-32B-Instruct) — hover a token to see the patched verbalization
↵
<code>↵
def is_simple_power(x, n):↵
"""Check if x is a simple power of n."""↵
if x == 1:↵
return True↵
if n <= 1:↵
return False↵
current = n↵
while current <= x:↵
if current == x:↵
return True↵
current *= n↵
return False↵
</code>