14 条题解

  • 1
    @ 2024-7-16 13:35:07
    #include <iomanip>
    #include<iostream>
    using namespace std;
    int main()
    {
        int n;
        cin >> n;
        double a = 0;
        if(n<150)
        {
            a = n * 0.4463;
        }
        else if(n >= 151 && n <= 400)
        {
            a = 150 * 0.4463 + (n - 150) * 0.4663;
        }
        else
        {
            a = 150 * 0.4463 + 250 * 0.4663 + (n - 400) * 0.5663;
        }
        cout << fixed << setprecision(1) << a;
        return 0;
    }
    

    加油^_^

    • 1
      @ 2024-7-16 10:46:27

      #include<bits/stdc++.h> using namespace std; int main(){ double a; cin>>a; if(a<=150){ printf("%.1lf",0.4463a); }if(a<=400 and a>150){ printf("%.1lf",0.4663(a-150)+0.4463150); }if(a>400){ printf("%.1lf",0.5663(a-400)+0.4463150+0.4663250); } return 0; }

      • 1
        @ 2024-2-23 9:44:19
        #include<bits/stdc++.h>
        using namespace std;
        int main(){
            double a;
            cin>>a;
            if(a<=150)printf("%.1lf",0.4463*a);
            if(a<=400 and a>150)printf("%.1lf",0.4663*(a-150)+0.4463*150);
            if(a>400)printf("%.1lf",0.5663*(a-400)+0.4463*150+0.4663*250);
            return 0;
        }
        
        • 0
          @ 2024-7-16 14:51:12
          #include<bits/stdc++.h>
          using namespace std;
          int main(){
              double a;
              cin>>a;
              if(a<=150)printf("%.1lf",0.4463*a);
              if(a<=400 and a>150)printf("%.1lf",0.4663*(a-150)+0.4463*150);
              if(a>400)printf("%.1lf",0.5663*(a-400)+0.4463*150+0.4663*250);
              return 0;
          }
          • 0
            @ 2024-3-20 17:43:37

            #include<bits/stdc++.h> using namespace std; int main(){ double a; cin>>a; if(a<=150)printf("%.1lf",0.4463a); if(a<=400 and a>150)printf("%.1lf",0.4663(a-150)+0.4463150); if(a>400)printf("%.1lf",0.5663(a-400)+0.4463150+0.4663250); return 0; }

            • 0
              @ 2024-3-17 10:04:17
              #include<bits/stdc++.h>
              using namespace std;
              int main(){
                  double a;
                  cin>>a;
                  if(a<=150)printf("%.1lf",0.4463*a);
                  if(a<=400 and a>150)printf("%.1lf",0.4663*(a-150)+0.4463*150);
                  if(a>400)printf("%.1lf",0.5663*(a-400)+0.4463*150+0.4663*250);
                  return 0;
              }
              
              • 0
                @ 2024-3-15 16:38:03
                #include<bits/stdc++.h>
                using namespace std;
                int main(){
                    double a;
                    cin>>a;
                    if(a<=150)printf("%.1lf",0.4463*a);
                    if(a<=400 and a>150)printf("%.1lf",0.4663*(a-150)+0.4463*150);
                    if(a>400)printf("%.1lf",0.5663*(a-400)+0.4463*150+0.4663*250);
                    return 0;
                }
                
                • 0
                  @ 2024-3-6 18:16:48

                  #include

                  using namespace std;

                  int main(){

                  float m,h,a;

                  cin>>m>>h;

                  a=m/(h*h);

                  if (a<18.5) cout<<"Underweigyht";

                  if (a>=18.5 and a<24) cout<<"Norymal";

                  else {

                  if (a>=24){

                  cout<<a<<enyudl;

                  cout<<"Overweijht";

                  }

                  }

                  return 0;

                  }

                  • 0
                    @ 2024-3-3 8:32:36
                    #include<bits/stdc++.h>
                    using namespace std;
                    int main(){
                        double a;
                        cin>>a;
                        if(a<=150)printf("%.1lf",0.4463*a);
                        if(a<=400 and a>150)printf("%.1lf",0.4663*(a-150)+0.4463*150);
                        if(a>400)printf("%.1lf",0.5663*(a-400)+0.4463*150+0.4663*250);
                        return 0;
                    }
                    
                    • -1
                      @ 2024-3-15 16:40:20

                      #include

                      using namespace std;

                      int main(){

                      float m,h,a;

                      cin>>m>>h;

                      a=m/(h*h);

                      if (a<18.5) cout<<"Underweigyht";

                      if (a>=18.5 and a<24) cout<<"Norymal";

                      else {

                      if (a>=24){

                      cout<<a<<enyudl;

                      cout<<"Overweijht";

                      }

                      }

                      return 0;

                      }

                      • -1
                        @ 2024-2-24 12:28:57

                        #include <bits/stdc++.h> using namespace std; int main() { double n,v; cin>>n; if(n>0&&n<=150) { v=n0.4463; } else if(n>150&&n<=400) { v=1500.4463+(n-150)0.4663; } else if(n>400) { v=1500.4463+(400-150)*0.4663+(n-400)*0.5663; } else { v=0.0; } printf("%.1f",v); return 0; }

                        • -1
                          @ 2024-2-23 18:07:15

                          #include<bits/stdc++.h> using namespace std; int main(){ int a; float b,c,d,e,f,g; cin>>a; b=0.4463; c=0.4663; d=0.5663; e=ab; f=(a-150)c+b150; g=(a-400)d+b150+c250; if(a<=150){ printf("%.1f",e); } else if(a>=151 and a<=400){ printf("%.1f",f); } else if(a>=401){ printf("%.1f",g); } return 0; }

                          • -1
                            @ 2024-2-23 9:23:35

                            #include<bits/stdc++.h> using namespace std; int main(){ int n; cin>>n; if(0<=n and n<=150){ printf("%.1f",n0.4463); } if(151<=n and n<=400){ printf("%.1f",1500.4463+(n-150)0.4663); } if(n>=401){ printf("%.1f",1500.4463+250*0.4663+(n-400)*0.5663); } return 0 ; }

                            • -3
                              @ 2024-2-23 10:58:11
                              #include<bits/stdc++.h>
                              using namespace std;
                              int main(){
                                  double a;
                                  cin>>a;
                                  if(a<=150)
                              {printf("%.1lf",0.4463*a);}
                                  if(a<=400 and a>150)
                              {printf("%.1lf",0.4663*(a-150)+0.4463*150);}
                                  if(a>400)
                              {printf("%.1lf",0.5663*(a-400)+0.4463*150+0.4663*250);}
                                  return 0;
                              }
                              
                              • 1

                              信息

                              ID
                              627
                              时间
                              1000ms
                              内存
                              125MiB
                              难度
                              4
                              标签
                              (无)
                              递交数
                              504
                              已通过
                              221
                              上传者