fork download
  1. #include <iostream>
  2.  
  3. int main()
  4. {
  5. int x;
  6. while(std::cin >> x)
  7. {
  8. switch(x)
  9. {
  10. case 1 ... 100: std::cout << "a"; break;
  11. default: std::cout << "b"; break;
  12. }
  13. }
  14. }
  15.  
Success #stdin #stdout 0s 3144KB
stdin
0
1
50
100
101
stdout
baaab