#include <bits/stdc++.h>
uint64_t fib[51];
void findperm(uint64_t n, uint64_t k, uint64_t offset) {
  assert(k <= fib[n]);
  if (n == 0) {
    puts("");
    return;
  }
  if (n == 1) {
    printf("%llu\n", offset);
    return;
  }
  if (k <= fib[n - 1]) {
    printf("%llu ", offset);
    findperm(n - 1, k, offset + 1);
  } else {
    printf("%llu %llu ", offset + 1, offset);
    findperm(n - 2, k - fib[n - 1], offset + 2);
  }
}
int main(void) {
  uint64_t n, k;
  fib[0] = 1;
  fib[1] = 1;
  for (size_t k = 2; k <= 50; k++) fib[k] = fib[k - 1] + fib[k - 2];
  scanf("%llu %llu", &n, &k);
  findperm(n, k, 1);
  return 0;
}
