#include <bits/stdc++.h>
using namespace std;
inline void readI(int *i) {
  register int t = 0;
  register char z = getchar();
  int znak = 1;
  if (z == '-') {
    znak = -1;
  }
  while ((z < '0') || ('9' < z)) {
    z = getchar();
    if (z == '-') {
      znak = -1;
    }
  }
  while (('0' <= z) && (z <= '9')) {
    t = (t << 3) + (t << 1) + z - '0';
    z = getchar();
  }
  *i = (t * znak);
}
inline void readUI(int *i) {
  register int t = 0;
  register char z = getchar();
  while ((z < '0') || ('9' < z)) {
    z = getchar();
  }
  while (('0' <= z) && (z <= '9')) {
    t = (t << 3) + (t << 1) + z - '0';
    z = getchar();
  }
  *i = t;
}
inline void readL(long long int *l) {
  register long long int t = 0;
  register char z = getchar();
  int znak = 1;
  if (z == '-') {
    znak *= -1;
  }
  while ((z < '0') || ('9' < z)) {
    z = getchar();
    if (z == '-') {
      znak = -1;
    }
  }
  while (('0' <= z) && (z <= '9')) {
    t = (t << 3) + (t << 1) + z - '0';
    z = getchar();
  }
  *l = (t * znak);
}
inline void readUL(long long int *l) {
  register long long int t = 0;
  register char z = getchar();
  while ((z < '0') || ('9' < z)) {
    z = getchar();
  }
  while (('0' <= z) && (z <= '9')) {
    t = (t << 3) + (t << 1) + z - '0';
    z = getchar();
  }
  *l = t;
}
inline void writeL(long long int l) {
  if (l == 0) {
    putchar(48);
  } else {
    if (l < 0) {
      l *= -1;
      putchar(45);
    }
    int _tab[21];
    int wsk = 0;
    while (l > 0) {
      ++wsk;
      _tab[wsk] = (l % 10) + 48;
      l /= 10;
    }
    for (int j = wsk; j >= 1; --j) {
      putchar(_tab[j]);
    }
  }
}
inline void writeS(string s) {
  int l = s.length();
  for (int i = 0; i < l; ++i) {
    putchar(s[i]);
  }
}
inline void space() { putchar(32); }
inline void endl() { putchar(10); }
int n, k, m, a, b, dl;
vector<int> v[((int)(2e5) + (int)(5e4) + 5)];
int g[((int)(2e5) + (int)(5e4) + 5)], oj[((int)(2e5) + (int)(5e4) + 5)];
bitset<((int)(2e5) + (int)(5e4) + 5)> lisc;
void PATH(int x) {
  fprintf(stdout, "PATH\n%d\n", g[x]);
  while (x) {
    fprintf(stdout, "%d ", x);
    x = oj[x];
  }
  exit(0);
}
void dfs(int x) {
  if (g[x] == dl) {
    PATH(x);
  }
  int l = v[x].size();
  lisc[x] = true;
  for (int i = 0; i < l; ++i) {
    if (!g[v[x][i]]) {
      lisc[x] = false;
      g[v[x][i]] = g[x] + 1;
      oj[v[x][i]] = x;
      dfs(v[x][i]);
    }
  }
}
int dist(int a, int b) { return abs(g[b] - g[a]) + 1; }
int main() {
  readUI(&n);
  readUI(&m);
  readUI(&k);
  dl = n / k;
  if (dl * k < n) {
    ++dl;
  }
  for (int i = 1; i <= m; ++i) {
    readUI(&a);
    readUI(&b);
    v[a].emplace_back(b);
    v[b].emplace_back(a);
  }
  g[1] = 1;
  dfs(1);
  fprintf(stdout, "CYCLES\n");
  for (int i = 1; i <= n; ++i) {
    if (lisc[i]) {
      int x, y;
      x = y = 0;
      int l = v[i].size();
      for (int j = 0; j < l; ++j) {
        if (oj[i] != v[i][j]) {
          if (!x) {
            x = v[i][j];
          } else if (!y) {
            y = v[i][j];
            break;
          }
        }
      }
      if (dist(i, x) % 3) {
        fprintf(stdout, "%d\n", dist(i, x));
        int a = i;
        fprintf(stdout, "%d ", a);
        while (a != x) {
          a = oj[a];
          fprintf(stdout, "%d ", a);
        }
      } else if (dist(i, y) % 3) {
        fprintf(stdout, "%d\n", dist(i, y));
        int a = i;
        fprintf(stdout, "%d ", a);
        while (a != y) {
          a = oj[a];
          fprintf(stdout, "%d ", a);
        }
      } else {
        fprintf(stdout, "%d\n%d ", dist(x, y) + 1, i);
        int a = (g[x] < g[y] ? y : x);
        int limit = (g[x] < g[y] ? x : y);
        fprintf(stdout, "%d ", a);
        while (a != limit) {
          a = oj[a];
          fprintf(stdout, "%d ", a);
        }
      }
      --k;
      if (!k) {
        return 0;
      }
      fprintf(stdout, "\n");
    }
  }
  return 0;
}
