#include <bits/stdc++.h>
using namespace std;
const long long Max = 2.5e5 + 10;
vector<long long> adj[Max];
bool visited[Max] = {0}, leaf[Max];
long long depth[Max] = {0}, parent[Max];
void dfs(long long node) {
  leaf[node] = true;
  visited[node] = true;
  for (long long to : adj[node]) {
    if (visited[to]) continue;
    leaf[node] = false;
    depth[to] = 1 + depth[node];
    parent[to] = node;
    dfs(to);
  }
}
int32_t main() {
  ios::sync_with_stdio(false);
  cin.tie(0);
  cout.tie(0);
  long long n, m, k;
  cin >> n >> m >> k;
  for (long long i = 0; i < m; ++i) {
    long long u, v;
    cin >> u >> v;
    adj[u].push_back(v);
    adj[v].push_back(u);
  }
  dfs(1);
  long long pathBound = (n + k - 1) / k;
  for (long long i = 1; i <= n; ++i) {
    if (depth[i] >= pathBound) {
      cout << "PATH\n";
      long long curr = i;
      vector<long long> res = {curr};
      while (curr != 1) {
        curr = parent[curr];
        res.push_back(curr);
      }
      cout << res.size() << '\n';
      for (long long i = (long long)res.size() - 1; i >= 0; --i) {
        cout << res[i] << ' ';
      }
      cout << '\n';
      return 0;
    }
  }
  vector<vector<long long>> cycles;
  for (long long i = 1; i <= n; ++i) {
    if (leaf[i]) {
      vector<long long> cycle;
      long long x = -1, y = -1;
      for (long long to : adj[i]) {
        if (to == parent[i]) continue;
        if (x == -1)
          x = to;
        else
          y = to;
      }
      bool found = false;
      long long dist = depth[i] - depth[x] + 1;
      if (dist % 3 != 0) {
        found = true;
        long long curr = i;
        cycle.push_back(curr);
        while (curr != x) {
          curr = parent[curr];
          cycle.push_back(curr);
        }
      }
      dist = depth[i] - depth[y] + 1;
      if (!found && dist % 3 != 0) {
        found = true;
        long long curr = i;
        cycle.push_back(curr);
        while (curr != y) {
          curr = parent[curr];
          cycle.push_back(curr);
        }
      }
      if (depth[x] < depth[y]) swap(x, y);
      dist = depth[x] - depth[y] + 2;
      if (!found) {
        long long curr = x;
        cycle.push_back(i);
        cycle.push_back(curr);
        while (curr != y) {
          curr = parent[curr];
          cycle.push_back(curr);
        }
      }
      cycles.push_back(cycle);
      if ((long long)cycles.size() >= k) break;
    }
  }
  cout << "CYCLES\n";
  for (auto &cycle : cycles) {
    cout << cycle.size() << '\n';
    for (long long x : cycle) cout << x << ' ';
    cout << '\n';
  }
  return 0;
}
