#include #include #include using namespace std ; using ll = long long ; ll mod = 1e9+7 ; ll modpow(ll a,ll b){ ll res = 1 ; while(b){ if(b&1) res = res*a%mod ; a = a*a%mod ; b >>= 1 ; } return res ; } int main(){ string n ; cin >> n ; int d = n.size() ; vector sum = {0,1,3,6,10,15,21,28,36,45} ; ll ans = sum[n[0]-'0'-1]*modpow(45,d-1)%mod ; ll mul = n[0]-'0' ; for(int i=1;i