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