#include <bits/stdc++.h>
using namespace std;
struct __s {
  __s() {
    if (1) {
      ios_base::Init i;
      cin.sync_with_stdio(0);
      cin.tie(0);
    }
  }
  ~__s() {
    if (!1)
      fprintf(stderr, "Execution time: %.3lf s.\n",
              (double)clock() / CLOCKS_PER_SEC);
    long long n;
    cin >> n;
  }
} __S;
long long a[1111111];
long long ai[1111111];
int main(void) {
  long long n;
  cin >> n;
  for (long long i = 0; i < (long long)(n); i++) {
    cin >> a[i];
    a[i]--;
    ai[a[i]] = i;
  }
  long long cnt = 0;
  for (long long i = 0; i < (long long)(n); i++) {
    if (i == a[i]) continue;
    long long j = ai[i];
    swap(a[i], a[j]);
    swap(ai[a[i]], ai[a[j]]);
    cnt++;
  }
  long long m1 = 3 * n - cnt;
  long long m2 = 7 * n + 1 - cnt;
  if (m1 % 2 == 0)
    cout << "Petr" << '\n';
  else
    cout << "Um_nik" << '\n';
  return 0;
}
