#include <bits/stdc++.h>
using namespace std;
int perm[52];
unsigned long long nways[52];
int n;
unsigned long long k;
void generate(int n, unsigned long long k, int start) {
  if (n < 1) return;
  if (n == 1) {
    perm[start] = start;
    return;
  }
  if (nways[n - 1] >= k) {
    perm[start] = start;
    generate(n - 1, k, start + 1);
  } else {
    perm[start] = start + 1;
    perm[start + 1] = start;
    generate(n - 2, k - nways[n - 1], start + 2);
  }
}
int main() {
  ios_base::sync_with_stdio(false);
  cin >> n >> k;
  nways[1] = 1;
  nways[2] = 2;
  for (int i = 3; i < n + 1; i++) {
    nways[i] = 1000000000000000001;
  }
  for (int i = 3; i < n + 1; i++) {
    nways[i] = min(nways[i], nways[i - 1] + nways[i - 2]);
  }
  generate(n, k, 1);
  for (int i = 1; i < n; i++) cout << perm[i] << ' ';
  cout << perm[n] << '\n';
  return 0;
}
