#include <bits/stdc++.h>
using namespace std;
const int N = 1000001;
int n, a[N], p[N];
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  cin >> n;
  for (int i = 1; i <= n; i++) {
    cin >> a[i];
    p[a[i]] = i;
  }
  int cnt = 0;
  for (int i = 1; i <= n; i++) {
    if (p[i] != i) {
      int L = p[i];
      swap(a[i], a[L]);
      p[a[L]] = L;
      cnt++;
    }
  }
  if ((3 * n - cnt) % 2 == 0)
    cout << "Petr" << endl;
  else
    cout << "Um_nik" << endl;
  return 0;
}
