Guest User

Untitled

a guest
Sep 26th, 2018
109
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.86 KB | None | 0 0
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int clas(double a);
  5.  
  6. int main()
  7. {
  8. double weight = 0;
  9.  
  10. while( cin >> weight ){
  11. clas(weight);
  12. }
  13. return 0;
  14. }
  15.  
  16. int clas(double a){
  17.  
  18. if (a <= 48.00){
  19. cout << "light fly" << endl;
  20. } else if(a >=48.00 && a <= 51.00){
  21. cout << "fly" << endl;
  22. } else if(a >= 51.00 && a <= 54.00){
  23. cout << "bantam" << endl;
  24. } else if(a >= 54.00 && a <= 57.00){
  25. cout << "feather" << endl;
  26. } else if(a >= 57.00 && a <= 60.00){
  27. cout << "light" << endl;
  28. } else if(a >= 60.00 && a <= 64.00){
  29. cout << "light welter" << endl;
  30. } else if(a >= 64.00 && a <= 69.00){
  31. cout << "welter" << endl;
  32. } else if(a >= 69.00 && a <= 75.00){
  33. cout << "light middle" << endl;
  34. } else if(a >= 75.00 && a <= 81.00){
  35. cout << "middle" << endl;
  36. } else if(a >= 81.00 && a <= 91.00){
  37. cout << "light heavy" << endl;
  38. } else {
  39. cout << "heavy" << endl;
  40. }
  41.  
  42. return 0;
  43. }
Add Comment
Please, Sign In to add comment