python remove last 3 characters of a string,foo = ''.join(foo.split())[:-3].upper()