#include <bits/stdc++.h>
const long long int loo = 2e18;
const int ioo = 2e9;
const int md = 1e9 + 7;
const double eps = 1e-6;
const double PI = acos(-1);
using namespace std;
int n, x;
int a[1000001];
int id[1000001];
int main() {
  scanf("%d", &n);
  for (int i = 0; i < n; i++) {
    scanf("%d", a + i);
    a[i]--;
    id[a[i]] = i;
  }
  for (int i = 0; i < n; i++) {
    if (a[i] != i) {
      id[a[i]] = id[i];
      swap(a[i], a[id[i]]);
      ++x;
    }
  }
  printf("%s\n", (3 * n - x) % 2 ? "Um_nik" : "Petr");
  return 0;
}
