20 条题解

  • 2
    @ 2024-7-16 14:46:25
    #include<bits/stdc++.h>
    using namespace std; 
    int main() {
    	double x,y;
    	cin>>x;
    	if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } 
    	if(5<=x && x<10) { y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20) { y=x/2-1.5; printf("%.3f",y); }
    	return 0; }
      
    
    • 1
      @ 2024-3-24 10:18:43
      #include<bits/stdc++.h>
      using namespace std; 
      int main() {
      	double x,y;
      	cin>>x;
      	if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } 
      	if(5<=x && x<10) { y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20) { y=x/2-1.5; printf("%.3f",y); }
      	return 0; }
      
      • 0
        @ 2024-7-16 13:48:59

        #include <bits/stdc++.h> using namespace std;

        int main(){ double x; cin>>x; double y; if(0<=x && x<5){ y=-x+2.5; }else if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); }else if(10<=x && x<20){ y=x/2-1.5; } cout<<fixed<<setprecision(3)<<y; return 0; }

        • 0
          @ 2024-7-16 10:43:54

          #include<bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } if(5<=x && x<10) { y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20) { y=x/2-1.5; printf("%.3f",y); } return 0; }

          • 0
            @ 2024-7-16 10:41:24

            #include<bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20){ y=x/2-1.5; printf("%.3f",y); } return 0; }

            • 0
              @ 2024-3-18 19:07:55
              #include<bits/stdc++.h>
              using namespace std; 
              int main() {
              	double x,y;
              	cin>>x;
              	if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } 
              	if(5<=x && x<10) { y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20) { y=x/2-1.5; printf("%.3f",y); }
              	return 0; }
              
              • 0
                @ 2024-3-17 9:50:26
                #include<bits/stdc++.h>
                using namespace std; 
                int main() {
                	double x,y;
                	cin>>x;
                	if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } 
                	if(5<=x && x<10) { y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20) { y=x/2-1.5; printf("%.3f",y); }
                	return 0; }
                
                • 0
                  @ 2024-3-6 17:58:50

                  #include<bits/stc++.h> using namespace std; int moin(){ doble x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y){ } if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20){ y=x/2-1.5; printf("%.3f",y); } return O;

                • -1
                  @ 2024-3-10 9:21:28

                  #include<bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(0<=x && x<5) { y=-x+2.5; printf("%.3f",y); } if(5<=x && x<10) { y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20) { y=x/2-1.5; printf("%.3f",y); } return 0; }

                  • -1
                    @ 2024-3-9 19:57:56

                    #include<bits/stdc++.h> using namespace std; int main(){ double x,y; cin>>x; if(0 <= x && x < 5){ y = -x+2.5; printf("%.3f",y); } if(5 <= x && x < 10){ y = 2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10 <= x && x < 20){ y = x/2-1.5; printf("%.3f",y); } return 0; }

                    • -1
                      @ 2024-3-6 18:06:40

                      #include<bits/stc++.h> using namespace std; int moin(){ doble x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y){ } if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20){ y=x/2-1.5; printf("%.3f",y); } return O;

                      • -3
                        @ 2024-3-3 10:34:02

                        #include <bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(x>=0&&x<5) { y=-x+2.5; } else if(x>=5&&x<10) { y=2-1.5*(x-3)*(x-3); } else if(x>=10&&x<20) { y=x/2-1.5; } else {

                        } printf("%.3f",y); return 0; }

                        • -5
                          @ 2024-3-3 9:03:07

                          #include <bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(x>=0&&x<5) { y=-x+2.5; } else if(x>=5&&x<10) { y=2-1.5*(x-3)*(x-3); } else if(x>=10&&x<20) { y=x/2-1.5; } else {

                          } printf("%.3f",y); return 0; }

                          • -7
                            @ 2024-3-2 17:34:57

                            #include <bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(x>=0&&x<5) { y=-x+2.5; } else if(x>=5&&x<10) { y=2-1.5*(x-3)*(x-3); } else if(x>=10&&x<20) { y=x/2-1.5; } else {

                            } printf("%.3f",y); return 0; }

                            • -9
                              @ 2024-2-23 16:30:55

                              #include<bits/stdc++.h>using namespace std;int main(){ double x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); }if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); printf("%.3f",y); }if(10<=x && x<20){ y=x/2-1.5; printf("%.3f",y);} return 0; }

                              • -9
                                @ 2024-1-17 9:05:24

                                #include<bits/stdc++.h>using namespace std;int main(){ double x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); }if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); printf("%.3f",y); }if(10<=x && x<20){ y=x/2-1.5; printf("%.3f",y);} return 0; }

                                • -18
                                  @ 2024-2-23 9:41:11

                                  #include<bits/stdc++.h> using namespace std; int main() { double x,y; cin>>x; if(0<=x && x<5){ y=-x+2.5; printf("%.3f",y); } if(5<=x && x<10){ y=2-1.5*(x-3)*(x-3); printf("%.3f",y); } if(10<=x && x<20){ y=x/2-1.5; printf("%.3f",y); } return 0; }

                                  • -21
                                    @ 2024-1-19 9:19:15
                                    #include<bits/stdc++.h>
                                    using namespace std;
                                    int main
                                    
                                    • -23
                                      @ 2024-1-16 21:10:57

                                      printf

                                      • 1

                                      信息

                                      ID
                                      97
                                      时间
                                      1000ms
                                      内存
                                      128MiB
                                      难度
                                      6
                                      标签
                                      (无)
                                      递交数
                                      963
                                      已通过
                                      272
                                      上传者