a, b = [int(x) for x in input().split()] wa = a + b seki = a * b if wa > seki: print('S') elif wa < seki: print('P') else: print('E')