fork download
  1. #include <iostream>
  2.  
  3. using namespace std;
  4.  
  5. int main()
  6. {
  7. int m,p;
  8. cin>> m;
  9. cin>> p;
  10. switch(m){
  11. case'1':
  12. cout << "Member";
  13. if(p>1100 && p<1300)
  14. {
  15. cout << "TOY-A" << endl;
  16. }
  17. else if(p>1300 && p<1900)
  18. {
  19. cout << "TOY-B" << endl;
  20. }
  21. else if(p>1900 && p<2700)
  22. {
  23. cout << "TOY-C" << endl;
  24. }
  25. else if(p>2700)
  26. {
  27. cout << "TOY-D" << endl;
  28. }
  29. else
  30. {
  31. cout << "No" << endl;
  32. }
  33. break;
  34. case'0':
  35. if(p>1150 && p<1350)
  36. {
  37. cout << "TOY-A" << endl;
  38. }
  39. else if(p>1350 && p<1950)
  40. {
  41. cout << "TOY-B" << endl;
  42. }
  43. else if(p>1950 && p<2750)
  44. {
  45. cout << "TOY-C" << endl;
  46. }
  47. else if(p>2750)
  48. {
  49. cout << "TOY-D" << endl;
  50. }
  51. else
  52. {
  53. cout << "No" << endl;
  54. }
  55. break;
  56. }
  57. return 0;
  58. }
Success #stdin #stdout 0.01s 5404KB
stdin
Standard input is empty
stdout
Standard output is empty