input_list = list(map(int,input().split())) a, b = input_list res = None if (a == 0 and b == 0) or (a == 2 and b == 2): res = 'E' elif (a == 1 or b == 1) or (a == 0 or b == 0): res = 'S' else: res = 'P' print(res)