a, b = map(int, input().split()) wa = a + b sk = a * b if wa > sk: print("S") elif wa == sk: print("E") else: print("P")