import java.util.Scanner; public class Main { public static void main(String[] args) { Scanner scan = new Scanner(System.in); var a = scan.nextBigInteger(); var b = scan.nextBigInteger(); if (a.add(b).compareTo(a.multiply(b)) > 0) { System.out.println("S"); } else if (a.add(b).compareTo(a.multiply(b)) < 0) { System.out.println("P"); } else { System.out.println("E"); } } }