d = map(int,raw_input().split())
a = d[0];b = d[1]
if a+b==a*b:
	print "E"
if a+b>a*b:
	print "S"
if a+b<a*b:
	print "P"