Enable Javascript in your browser and then refresh this page, for a much enhanced experience.
First solution in Clear category for Letter Queue by xiongbiao
def letter_queue(commands):
l = []
for i in commands:
if i[1] == 'U':
l.append(i[5:])
else:
if len(l) != 0:
del l[0]
return "".join(l)
July 13, 2014
Comments: