#include using namespace std; int main(){ int n;cin>>n; int digit = (n+35)/36; int k = (n+35)%36; int nw = 8; int x = 1; while(k-nw > 0){ k -= nw; nw--; x++; } cout << x; for(int i = 0; digit > i; i++){ cout << x+k+1; } cout << endl; }