1326A - Bad Ugly Numbers

  1. #include<math.h>
  2. #include<iostream>
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7. int n;
  8. int t;
  9. cin>>t;
  10. while(t--){
  11. cin>>n;
  12. if(n==1) cout<<-1<<endl;
  13. else {cout<<"2";
  14. for(int i=1;i<n;i++)
  15.  
  16. cout<<"3";
  17.  
  18.  
  19. }
  20. cout<<endl;
  21. }
  22.  
  23.  
  24. }
  25.  

Comments

Popular posts from this blog

Codeforce Problem 1703A. YES or YES?

1535A. Fair Playoff

Aptitude test assistant programmer 2018