Codeforces 1326A. Bad Ugly Numbers Solution
Solution in c++:
///**********ALLAH IS ALMIGHTY************///
///AH Tonmoy
///Department of CSE,23rd batch
///Islamic University,Bangladesh
///**********ALLAH IS ALMIGHTY************///
///AH Tonmoy
///Department of CSE,23rd batch
///Islamic University,Bangladesh
- #include <bits/stdc++.h>
- using namespace std;
- int main()
- {int t,n;
- cin >> t;
- while(t--)
- { cin >> n;
- if(n==1)
- cout<<"-1"<<endl;
- else
- cout<<string(n-1,'9')<<8<<endl;
- }
- }
No comments