#include int main(void){ char a[202], b[202]; scanf("%s%s", a, b); if ((a[0] == '0' && a[1] == '\0' && b[0] == '0' && b[1] == '\0') || (a[0] == '2' && a[1] == '\0' && b[0] == '2' && b[1] == '\0')) printf("E\n"); else if((a[0] == '0' && a[1] == '\0') || (b[0] == '0' && b[1] == '\0')) printf("S\n"); else printf("P\n"); return 0; }