#include <bits/stdc++.h>
using namespace std;
long long modpow(long long b, long long e, long long mod) {
  long long ans = 1;
  for (; e; b = b * b % mod, e /= 2)
    if (e & 1) ans = ans * b % mod;
  return ans;
}
const int N = 300005;
vector<int> g[N], curr;
vector<vector<int> > cycles;
int pai[N], d[N];
bool vis[N];
int n, m, k;
void dfs(int x) {
  vis[x] = true;
  curr.push_back(x);
  if ((int)(curr).size() * k >= n) {
    cout << "PATH" << endl;
    cout << (int)(curr).size() << endl;
    for (auto w : curr) {
      cout << w << " ";
    }
    cout << endl;
    exit(0);
  }
  bool entrou = false;
  for (auto w : g[x]) {
    if (!vis[w]) {
      pai[w] = x;
      d[w] = d[x] + 1;
      dfs(w);
      entrou = true;
    }
  }
  curr.pop_back();
  if (!entrou) {
    vector<int> currc;
    int a = -1, b = -1;
    for (auto w : g[x]) {
      if (w == pai[x]) continue;
      if (a == -1)
        a = w;
      else
        b = w;
    }
    if (d[a] > d[b]) swap(a, b);
    if ((d[x] - d[a] + 1) > 3 && (d[x] - d[a] + 1) % 3) {
      while (x != a) {
        currc.push_back(x);
        x = pai[x];
      }
      currc.push_back(x);
    } else if ((d[x] - d[b] + 1) > 3 && (d[x] - d[b] + 1) % 3) {
      while (x != b) {
        currc.push_back(x);
        x = pai[x];
      }
      currc.push_back(x);
    } else {
      currc.push_back(x);
      while (b != a) {
        currc.push_back(b);
        b = pai[b];
      }
      currc.push_back(b);
    }
    cycles.push_back(currc);
    if ((int)(cycles).size() == k) {
      cout << "CYCLES" << endl;
      for (auto w : cycles) {
        cout << (int)(w).size() << endl;
        for (auto k : w) {
          cout << k << " ";
        }
        cout << endl;
      }
      exit(0);
    }
  }
}
int32_t main() {
  ios::sync_with_stdio(false);
  cin.tie(0), cout.tie(0);
  cin >> n >> m >> k;
  for (int i = 0; i < (m); ++i) {
    int x, y;
    cin >> x >> y;
    g[x].push_back(y);
    g[y].push_back(x);
  }
  dfs(1);
  cout << -1 << endl;
}
