Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Uncategorized category for Follow Instructions by Pactp
def follow(instructions: str) -> tuple[int, int] | list[int]:
dx = instructions.count('r') - instructions.count('l')
dy = instructions.count('f') - instructions.count('b')
return [dx, dy]
March 18, 2023
Comments: