#include <iostream>
#include <algorithm>
using namespace std;

string itob(int x);
int main() 
{
    ios::sync_with_stdio(false);
    cin.tie(0);
    int n;
    string str;
    while(cin>>n)
    {
        str=itob(n);
        cout<<str<<endl;
    }
}

string itob(int x)
{
    string str;
    if(x==0) str="0";
    while(x!=0)
    {
        str.push_back('0'+x%2);
        x=x>>1;
    }
    reverse(str.begin(),str.end());
    return str;
}