fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int x[18]= {0,10,1,22,6,123,12,1124,40,11125,30,111126,84,1111127,224,11111128,144,111111129};
  6. int n;
  7. cin>>n;
  8. cout<<x[2*n-2]<<" "<<x[2*n-1];
  9. return 0;
  10. }
Success #stdin #stdout 0s 4328KB
stdin
2
stdout
1 22