#include <bits/stdc++.h>
using namespace std;
const long double pi = 3.1415926535897932384626433832795l;
template <typename T>
inline auto sqr(T x) -> decltype(x * x) {
  return x * x;
}
template <typename T1, typename T2>
inline bool umx(T1& a, T2 b) {
  if (a < b) {
    a = b;
    return 1;
  }
  return 0;
}
template <typename T1, typename T2>
inline bool umn(T1& a, T2 b) {
  if (b < a) {
    a = b;
    return 1;
  }
  return 0;
}
const int N = 1000100;
int p[N];
bool use[N];
int main() {
  std::ios::sync_with_stdio(false);
  cout.setf(ios::showpoint | ios::fixed);
  cout.precision(20);
  int n;
  cin >> n;
  for (int i = int(0); i < int(n); ++i) {
    cin >> p[i];
    p[i]--;
  }
  int res = n;
  for (int i = int(0); i < int(n); ++i) {
    if (use[i]) continue;
    int cur = i;
    while (!use[cur]) {
      use[cur] = 1;
      cur = p[cur];
    }
    res--;
  }
  if (((n & 1) ^ (res & 1)) == 0) {
    cout << "Petr";
  } else {
    cout << "Um_nik";
  }
  return 0;
}
