#include <bits/stdc++.h>
#ifdef LOCAL
#include "C:\Users\15328\Desktop\isaunoya.hpp"
#define debug(...) cerr << "[" << #__VA_ARGS__ << "]:", debug_out(__VA_ARGS__)
#else
#define debug(...) 42
#endif
using namespace std;
long long fib[100];
bool book[100];
int main() {
	cin.tie(nullptr)->sync_with_stdio(false);
	fib[0] = 1;
	fib[1] = 1;
	for (int i = 2; i < 87; i++) {
		fib[i] = fib[i - 1] + fib[i - 2];
	}
	long long n;
	cin >> n;
	for (int i = 86; i >= 0; i--) {
		if (n >= fib[i]) {
			n -= fib[i];
			book[i] = true;
		}
	}
	vector<int> ans;
	for (int i = 0; i < 87; i++) {
		if (i % 2 == 0) {
			if (book[i]) {
				ans.emplace_back(1);
			}
			ans.emplace_back(3);
		} else {
			if (book[i]) {
				ans.emplace_back(2);
			}
			ans.emplace_back(4);
		}
	}
	reverse(begin(ans), end(ans));
	cout << ans.size() << "\n";
	for (int i = 0; i < int(ans.size()); i++) {
		cout << ans[i] << "\n";
	}
}

#include <bits/stdc++.h>
#define FASTIO
using namespace std;

using ll = long long;
using Vi = std::vector<int>;
using Vl = std::vector<ll>;
using Pii = std::pair<int, int>;
using Pll = std::pair<ll, ll>;

constexpr int I_INF = std::numeric_limits<int>::max();
constexpr ll L_INF = std::numeric_limits<ll>::max();

template <typename T1, typename T2>
inline bool chmin(T1& a, const T2& b) {
    if (a > b) {
        a = b;
        return true;
    }
    return false;
}
template <typename T1, typename T2>
inline bool chmax(T1& a, const T2& b) {
    if (a < b) {
        a = b;
        return true;
    }
    return false;
}

template <std::ostream& os = std::cout>
class Prints {
private:
    class __Prints {
    public:
        __Prints(const char* sep, const char* term) : sep(sep), term(term) {}
        template <class... Args>
#if __cplusplus >= 201703L
        auto operator()(const Args&... args) const -> decltype((os << ... << std::declval<Args>()), void()) {
#else
        void operator()(const Args&... args) const {
#endif
            print(args...);
        }
        template <typename T>
#if __cplusplus >= 201703L
        auto pvec(const T& vec, size_t sz) const -> decltype(os << std::declval<decltype(std::declval<T>()[0])>(), void()) {
#else
        void pvec(const T& vec, size_t sz) const {
#endif
            for (size_t i = 0; i < sz; i++)
                os << vec[i] << (i == sz - 1 ? term : sep);
        }
        template <typename T>
#if __cplusplus >= 201703L
        auto pmat(const T& mat, size_t h, size_t w) const -> decltype(os << std::declval<decltype(std::declval<T>()[0][0])>(), void()) {
#else
        void pmat(const T& mat, size_t h, size_t w) const {
#endif
            for (size_t i = 0; i < h; i++)
                for (size_t j = 0; j < w; j++)
                    os << mat[i][j] << (j == w - 1 ? term : sep);
        }

    private:
        const char *sep, *term;
        void print() const { os << term; }
        void print_rest() const { os << term; }
        template <class T, class... Tail>
        void print(const T& head, const Tail&... tail) const { os << head, print_rest(tail...); }
        template <class T, class... Tail>
        void print_rest(const T& head, const Tail&... tail) const { os << sep << head, print_rest(tail...); }
    };

public:
    Prints() {}
    __Prints operator()(const char* sep = " ", const char* term = "\n") const { return __Prints(sep, term); }
};

Prints<> prints;
Prints<std::cerr> prints_err;

//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

void solve() {
    ll N;
    cin >> N;
    Vl fib;
    fib.emplace_back(1);
    fib.emplace_back(1);
    while (true) {
        ll sz = (ll)fib.size();
        ll t = fib[sz - 1] + fib[sz - 2];
        if (t <= N) {
            fib.emplace_back(t);
        } else {
            break;
        }
    }
    ll sz = (ll)fib.size();
    Vi ans;
    for (ll i = 0; i < sz; i++) {
        if ((sz - 1 - i) % 2 == 0) {
            if (N >= fib[sz - 1 - i]) {
                ans.emplace_back(1);
                N -= fib[sz - 1 - i];
            }
            ans.emplace_back(4);
        } else {
            if (N >= fib[sz - 1 - i]) {
                ans.emplace_back(2);
                N -= fib[sz - 1 - i];
            }
            ans.emplace_back(3);
        }
    }
    prints()(ans.size());
    for (auto x : ans) {
        prints()(x);
    }
}

//%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%

int main() {
#ifdef FASTIO
    std::cin.tie(nullptr), std::cout.tie(nullptr);
    std::ios::sync_with_stdio(false);
#endif
#ifdef FILEINPUT
    std::ifstream ifs("./in_out/input.txt");
    std::cin.rdbuf(ifs.rdbuf());
#endif
#ifdef FILEOUTPUT
    std::ofstream ofs("./in_out/output.txt");
    std::cout.rdbuf(ofs.rdbuf());
#endif
    std::cout << std::setprecision(18) << std::fixed;
    solve();
    std::cout << std::flush;
    return 0;
}