#include <bits/stdc++.h>
using namespace std;
vector<vector<int> > g;
vector<int> pr, vs, dp;
vector<int> lf;
int md = -1, mv = -1;
void dfs(int v) {
  int ct = 0;
  vs[v] = 1;
  for (int i = 0; i < g[v].size(); i++) {
    int u = g[v][i];
    if (vs[u] == 0) {
      dp[u] = dp[v] + 1;
      pr[u] = v;
      dfs(u);
      ct++;
    }
  }
  if (ct == 0) {
    lf.push_back(v);
    if (dp[v] > md) {
      md = dp[v];
      mv = v;
    }
  }
  vs[v] = 2;
}
int main() {
  int n, m, k;
  scanf("%d %d %d ", &n, &m, &k);
  g.assign(n, vector<int>());
  pr.assign(n, -1);
  dp.assign(n, 0);
  vs.assign(n, 0);
  while (m--) {
    int a, b;
    scanf("%d %d ", &a, &b);
    a--;
    b--;
    g[a].push_back(b);
    g[b].push_back(a);
  }
  dfs(0);
  if (md >= n / k) {
    printf("PATH\n");
    printf("%d\n", md + 1);
    int v = mv;
    while (v != -1) {
      printf("%d", v + 1);
      v = pr[v];
      if (v != -1) {
        printf(" ");
      }
    }
    printf("\n");
  } else if (lf.size() >= k) {
    printf("CYCLES\n");
    for (int i = 0; i < k; i++) {
      int v = lf[i];
      int be[2], ct = 0, du[2], dv = dp[v];
      for (int j = 0; j < g[v].size(); j++) {
        int u = g[v][j];
        if (u == pr[v]) {
          continue;
        }
        be[ct++] = u;
        if (ct == 2) {
          break;
        }
      }
      if (dp[be[0]] > dp[be[1]]) {
        swap(be[0], be[1]);
      }
      du[0] = dp[be[0]];
      du[1] = dp[be[1]];
      if ((dv - du[0] + 1) % 3) {
        printf("%d\n", dv - du[0] + 1);
        int t = v;
        printf("%d", v + 1);
        while (t != be[0]) {
          t = pr[t];
          printf(" %d", t + 1);
        }
        printf("\n");
      } else if ((dv - du[1] + 1) % 3) {
        printf("%d\n", dv - du[1] + 1);
        int t = v;
        printf("%d", v + 1);
        while (t != be[1]) {
          t = pr[t];
          printf(" %d", t + 1);
        }
        printf("\n");
      } else {
        printf("%d\n", du[1] - du[0] + 2);
        int t = be[1];
        printf("%d", v + 1);
        while (t != be[0]) {
          printf(" %d", t + 1);
          t = pr[t];
        }
        printf(" %d\n", t + 1);
      }
    }
  } else {
    printf("-1\n");
  }
}
