#include <bits/stdc++.h>
using namespace std;
const int INF = 0x3f3f3f3f;
const long long LINF = 0x3f3f3f3f3f3f3f3f;
const long long mod = 1e9 + 7;
const double PI = acos(-1.0);
const double eps = 1e-10;
const int N = 1e6 + 5;
int n, a[N], p[N];
int main() {
  scanf("%d", &n);
  for (int i = 1; i <= n; i++) {
    scanf("%d", a + i);
    p[a[i]] = i;
  }
  int num = 0;
  for (int i = 1; i <= n; i++) {
    if (p[i] != i) {
      p[a[i]] = p[i];
      swap(a[i], a[p[i]]);
      num++;
    }
  }
  bool peter = !((3 * n - num) & 1);
  bool alex = !((7 * n + 1 - num) & 1);
  if (peter)
    puts("Petr");
  else if (alex)
    puts("Um_nik");
  return 0;
}
