A, B = map(int, input().split()) if A == 0 or B == 0 or A == 1 or B == 1: print("S") elif A == B == 2 or A == B == 0: print("E") else: print("P")