#include <bits/stdc++.h>
using namespace std;
long long int m, n;
long long int a[55];
int vis[55] = {0};
int main() {
  int i, j;
  scanf("%lld %lld", &m, &n);
  a[0] = 1, a[1] = 1;
  for (i = 2; i < 55; i++) {
    a[i] = a[i - 1] + a[i - 2];
  }
  n--;
  for (i = m; i > 1; i--) {
    int t = n / a[i - 1];
    int qwe = 0;
    for (j = 1; j < m; j++) {
      if (vis[j] == 0) {
        qwe++;
        if (qwe == t + 1) break;
      }
    }
    printf("%d ", j);
    vis[j] = 1;
    n = n % a[i - 1];
  }
  for (i = 1; i <= m; i++) {
    if (vis[i] == 0) printf("%d\n", i);
  }
  return 0;
}
