#include <bits/stdc++.h>
using namespace std;
using Graph = vector<vector<int>>;
void dfsB(int v, int pre, Graph& g, Graph& tree, Graph& rest, vector<int>& used,
          vector<int>& prev) {
  prev[v] = pre;
  used[v] = true;
  for (auto to : g[v]) {
    if (to == pre) continue;
    if (used[to]) {
      rest[v].push_back(to);
    } else {
      tree[v].push_back(to);
      dfsB(to, v, g, tree, rest, used, prev);
    }
  }
}
void build(Graph& g, Graph& tree, Graph& rest, vector<int>& prev) {
  vector<int> used(g.size());
  dfsB(0, -1, g, tree, rest, used, prev);
}
void dfsD(int v, Graph& tree, vector<int>& dep) {
  for (auto to : tree[v]) {
    dep[to] = dep[v] + 1;
    dfsD(to, tree, dep);
  }
}
void answerPath(int v, vector<int>& prev) {
  vector<int> res;
  res.push_back(v);
  while (prev[v] != -1) {
    v = prev[v];
    res.push_back(v);
  }
  cout << "PATH" << endl;
  cout << res.size() << endl;
  for (int i = 0; i < res.size(); i++) {
    cout << res[i] + 1 << (i + 1 == res.size() ? "\n" : " ");
  }
  return;
}
void answerCycle(vector<vector<int>>& cycle) {
  cout << "CYCLES" << endl;
  for (int i = 0; i < cycle.size(); i++) {
    cout << cycle[i].size() << "\n";
    for (int j = 0; j < cycle[i].size(); j++) {
      cout << cycle[i][j] + 1 << (j + 1 == cycle[i].size() ? "\n" : " ");
    }
  }
}
int main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  int k, n, m;
  cin >> n >> m >> k;
  Graph g(n);
  for (int i = 0; i < m; i++) {
    int u, v;
    cin >> u >> v;
    u--, v--;
    g[u].push_back(v);
    g[v].push_back(u);
  }
  vector<int> prev(n);
  Graph tree(n);
  Graph rest(n);
  build(g, tree, rest, prev);
  vector<int> dep(n);
  dep[0] = 0;
  dfsD(0, tree, dep);
  auto it = max_element(dep.begin(), dep.end());
  if (*it >= (n + k - 1) / k) {
    answerPath(it - dep.begin(), prev);
    return 0;
  }
  vector<int> leaf;
  for (int i = 0; i < n; i++)
    if (tree[i].size() == 0) leaf.push_back(i);
  assert(leaf.size() >= k);
  auto createCycle = [&](int v) {
    vector<int> res;
    res.push_back(v);
    int last = -1;
    if (dep[rest[v][0]] < dep[rest[v][1]]) swap(rest[v][0], rest[v][1]);
    if ((dep[v] - dep[rest[v][0]] + 1) % 3 != 0) last = rest[v][0];
    if ((dep[v] - dep[rest[v][1]] + 1) % 3 != 0) last = rest[v][1];
    int s;
    if (last == -1) {
      res.push_back(rest[v][0]);
      last = rest[v][1];
      s = rest[v][0];
    } else {
      s = v;
    }
    while (s != last) {
      s = prev[s];
      res.push_back(s);
    }
    return res;
  };
  vector<vector<int>> cycle(k);
  for (int i = 0; i < k; i++) {
    cycle[i] = createCycle(leaf[i]);
  }
  answerCycle(cycle);
  return 0;
}
