fork download
  1. #include <iostream>
  2. using namespace std;
  3.  
  4. int main() {
  5. int waga,wzrost,BMI;
  6. cin>>waga>>wzrost;
  7. BMI=(waga*10000)/(wzrost*wzrost);
  8. if(BMI<21)cout<<"niedowaga"<<endl;
  9. else
  10. if(BMI>25)cout<<"nadwaga"<<endl;
  11. else
  12. cout<<"norma"<<endl;
  13. return 0;
  14. }
Success #stdin #stdout 0.01s 5284KB
stdin
90 180
stdout
nadwaga