fork(1) download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int n, a, b;
  6. cin >> n >> a >> b;
  7. string s;
  8. if (a + b == 0) cout << 0 << endl;
  9. else
  10. {
  11. if ((a == b) or !(a * b)) cout << 1;
  12. else cout << 2;
  13. for (int i = 0; i < n - 1; i++) s += '0';
  14. cout << s << endl;
  15. }
  16. return 0;
  17. }
Success #stdin #stdout 0s 4336KB
stdin
3 3 3
stdout
100