Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
collections.Counter solution in Clear category for Follow Instructions by David_Jones
from collections import Counter
def follow(instructions):
c = Counter(instructions)
return (c['r'] - c['l'], c['f'] - c['b'])
May 20, 2019