generate functionTue, 07 Mar 2023

Check that the number has no consecutive identical digits

def check_num(x): return int(x) == int(''.join(sorted(x))) check_num('123')

Want to kickstart your project?Use the new AI Studio to create your code