using System; using System.Collections.Generic; using System.Linq; namespace yukicodeX { public class ProgramX { public static string Solver(System.IO.TextReader reader) { var buf = reader.ReadLine().Split(); if (buf[ 0 ] == "0" || buf[ 1 ] == "0" || buf[ 0 ] == "1" || buf[ 1 ] == "1") return "S"; if (buf[ 0 ] == "2" && buf[ 1 ] == "2") return "E"; else return "P"; } private static void Main() { Console.WriteLine( Solver( Console.In ) ); } } }