#include using namespace std; int main() { int n; cin >> n; int t = n / 36; int r = n % 36; for (int i = 1; i < 9; i++) { if (r + i <= 9) { cout << i; for (int j = 0; j <= t; j++) { cout << i + r; } cout << endl; break; } r -= 9 - i; } }