#include <bits/stdc++.h>
using namespace std;
bool cmp_P(const pair<long long int, long long int> &a,
           const pair<long long int, long long int> &b) {
  return a.second < b.second;
}
int main() {
  int N;
  string s = "";
  cin >> N;
  while (N != 0) {
    if (N % 2 != 0) {
      N--;
      s = "1" + s;
    } else
      s = "0" + s;
    N /= -2;
    if (s == "") s = "0";
  }
  cout << s << endl;
  return 0;
}
