A, B = map(int, input().split())
S = A+B
P = A*B
if S>P:
    print("S")
elif P > S:
    print("P")
else:
    print("E")