9 solutions

  • 2
    @ 2025-3-28 16:52:04

    #include<bits/stdc++.h> using namespace std; float m,h,ans; int main(){ cin>>m>>h; ans=m/(h*h); if(ans<18.5){ cout<<"Underweight"; } else if(ans>=18.5&&ans<24){ cout<<"Normal"; } else if(ans>=24){ cout<<ans<<"\n"<<"Overweight"; } return 0; }

  • 1
    @ 2025-12-6 21:41:12

    #include<bits/stdc++.h> using namespace std; float m,h,ans; int main(){ cin>>m>>h; ans=m/(h*h); if(ans<18.5) { cout<<"Underweight"; } else if(ans>=18.5&&ans<24) { cout<<"Normal"; } else if(ans>=24) { cout<<ans<<"\n"<<"Overweight"; } } 拿去抄吧,不用谢

    • -3
      @ 2025-4-11 17:59:24

      #include<bits/stdc++.h> using namespace std; float m,h,ans; int main() { cin>>m>>h; ans=m/(h*h); if(ans<18.5){ cout<<"Underweight"; } else if(ans>=18.5&&ans<24){ cout<<"Normal"; } else if(ans>=24) { cout<<ans<<"\n"<<"Overweight"; } return 0; }

      • -4
        @ 2025-4-16 18:19:01
        #include<bits/stdc++.h>
        using namespace std;
        float m,h,ans;
        int main(){ 
            cin>>m>>h; 
            ans=m/(h*h); 
            if(ans<18.5)
            { 
                cout<<"Underweight"; 
            } 
            else if(ans>=18.5&&ans<24)
            {
                 cout<<"Normal";
            } 
            else if(ans>=24)
            {
                 cout<<ans<<"\n"<<"Overweight"; 
            } 
            return 0;
        }
        

        我才是救星😎

        • -4
          @ 2025-4-11 18:00:43

          想p吃

          • -4
            @ 2025-4-11 17:55:23

            #include<bits/stdc++.h> using namespace std; int main(){ double m,h,bmi; cin>>m>>h; bmi=m/(h*h); if(bmi<18.5) cout<<"Underweight"<<endl; else if(bmi>=18.5&&bmi<24) cout<<"Normal"; else if(bmi>=24) cout<<bmi<<endl<<"Overweight"<<endl;

            return 0;
            

            }

            • -4
              @ 2025-4-11 17:42:45

              @ 2 周前 #include<bits/stdc++.h> using namespace std; float m,h,ans; int main(){ cin>>m>>h; ans=m/(h*h); if(ans<18.5){ cout<<"Underweight"; } else if(ans>=18.5&&ans<24){ cout<<"Normal"; } else if(ans>=24){ cout<<ans<<"\n"<<"Overweight"; } return 0; }

              • -4
                @ 2025-4-11 17:29:22

                #include<bits/stdc++.h> using namespace std; float m,h,ans; int main(){ cin>>m>>h; ans=m/(h*h); if(ans<18.5){ cout<<"Underweight"; } else if(ans>=18.5&&ans<24){ cout<<"Normal"; } else if(ans>=24){ cout<<ans<<"\n"<<"Overweight"; } return 0; }

                • -4
                  @ 2025-4-11 17:24:39

                  周政仰 (lqst2025051) LV 7 MOD @ 2 周前 #include<bits/stdc++.h> using namespace std; float m,h,ans; int main(){ cin>>m>>h; ans=m/(h*h); if(ans<18.5){ cout<<"Underweight"; } else if(ans>=18.5&&ans<24){ cout<<"Normal"; } else if(ans>=24){ cout<<ans<<"\n"<<"Overweight"; } return 0; }

                • 1

                Information

                ID
                1342
                Time
                1000ms
                Memory
                256MiB
                Difficulty
                3
                Tags
                (None)
                # Submissions
                124
                Accepted
                67
                Uploaded By