from collections import Counter
inputs = 'URLDFLDLFUBBDUBLRtroooooool'
print(max('UDLRFB', key=Counter(inputs).get))