import sys read = sys.stdin.buffer.read readline = sys.stdin.buffer.readline readlines = sys.stdin.buffer.readlines sys.setrecursionlimit(10 ** 7) a, b = map(int, readline().split()) if a * b > a + b: print('P') elif a * b == a + b: print('E') else: print('S')