#include <bits/stdc++.h>
using namespace std;
const int NMAX = 1000010;
int n;
int a[NMAX], b[NMAX];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", &a[i]);
    b[a[i]] = i;
  }
  int cnt = 0;
  for (int i = 1; i <= n; i++) {
    if (a[i] != i) {
      swap(a[i], a[b[i]]);
      b[a[b[i]]] = b[i];
      cnt += 1;
    }
  }
  if ((cnt & 1) == ((3 * n) & 1))
    printf("Petr\n");
  else
    printf("Um_nik\n");
  return 0;
}
