#include <bits/stdc++.h>
using namespace std;
const int MAXN = 3e5 + 5;
const int MAXM = 5e5 + 5;
struct edge {
  int to, next, w;
} e[MAXM * 2];
int cnt = 0;
int head[MAXN];
void add_edge(int u, int v, int w) {
  e[++cnt].to = v;
  e[cnt].next = head[u];
  e[cnt].w = w;
  head[u] = cnt;
}
int vis[MAXN], dis[MAXN], pre[MAXN];
int ans = 0;
vector<int> backe[MAXN];
vector<int> leaf;
void dfs(int u) {
  vis[u] = 1;
  if (dis[u] > dis[ans]) ans = u;
  int f = 1;
  for (int i = head[u]; i; i = e[i].next) {
    int v = e[i].to;
    if (vis[v]) {
      if (v != pre[u]) backe[u].push_back(v);
      continue;
    }
    f = 0;
    dis[v] = dis[u] + 1;
    pre[v] = u;
    dfs(v);
  }
  if (f) leaf.push_back(u);
}
vector<vector<int> > circle;
void check(int u) {
  int p1 = backe[u][0], p2 = backe[u][1];
  if (dis[p1] < dis[p2]) swap(p1, p2);
  vector<int> a, b, c;
  int tmp = u;
  while (tmp != p1) {
    a.push_back(tmp);
    tmp = pre[tmp];
  }
  a.push_back(p1);
  if ((int)a.size() > 3 && (int)a.size() % 3 != 0) {
    circle.push_back(a);
    return;
  }
  tmp = u;
  while (tmp != p2) {
    b.push_back(tmp);
    tmp = pre[tmp];
  }
  b.push_back(p2);
  if ((int)b.size() > 3 && (int)b.size() % 3 != 0) {
    circle.push_back(b);
    return;
  }
  c.push_back(u);
  c.push_back(p1);
  tmp = pre[p1];
  while (tmp != p2) {
    c.push_back(tmp);
    tmp = pre[tmp];
  }
  c.push_back(p2);
  if ((int)c.size() > 3 && (int)c.size() % 3 != 0) {
    circle.push_back(c);
    return;
  }
}
int main() {
  int n, m, k;
  scanf("%d%d%d", &n, &m, &k);
  for (int i = 0; i < m; i++) {
    int u, v;
    scanf("%d%d", &u, &v);
    add_edge(u, v, 1);
    add_edge(v, u, 1);
  }
  dfs(1);
  if (dis[ans] * k > n) {
    printf("PATH\n");
    vector<int> tmp;
    while (ans != 0) {
      tmp.push_back(ans);
      ans = pre[ans];
    }
    printf("%d\n", (int)tmp.size());
    for (int i = 0; i < (int)tmp.size(); i++) printf("%d ", tmp[i]);
    return 0;
  }
  for (int i = 0; i < k; i++) check(leaf[i]);
  printf("CYCLES\n");
  for (int i = 0; i < k; i++) {
    printf("%d\n", (int)circle[i].size());
    for (int j = 0; j < (int)circle[i].size(); j++) printf("%d ", circle[i][j]);
    printf("\n");
  }
}
