4 条题解

  • 0
    @ 2023-11-25 13:33:11
    #include<bits/stdc++.h>
    using namespace std;
    int main(){
        int n;
        double x;
        cin>>x>>n;
        for(int i=1;i<=n;i++){
            x*=1.001;
        }
        cout<<fixed<<setprecision(4)<<x;
        return 0;
    }
    
    • 0
      @ 2023-3-21 20:40:00

      #include<bits/stdc++.h> using namespace std; int main() { double x; int n; cin>>x>>n; for (int i=1;i<=n;i++) { x+=x*0.001; } cout<<fixed<<setprecision(4)<<x; return 0; }

      • 0
        @ 2022-11-6 21:53:30
        #include <iostream>
        
        #include <iomanip>
        
        using namespace std;
        
        int main()
        
        {
        
        double x;
        
        int n;
        
        cin >> x >> n;
        
        for (int i = 1; i <= n; i++)
        
        {
        
        x += x * 0.001;
        
        }
        
        cout << fixed << setprecision(4) << x;
        
        return 0;
        
        }
        
        • -3
          @ 2023-11-25 13:17:36

          #include<bits/stdc++.h>

          using namespace std;

          int main()

          {

          double x;

          int n;

          cin >> x >> n;

          for (int i = 1; i <= n; i++)

          {

          x += x * 0.001;

          }

          cout << fixed << setprecision(4) << x;

          return 0;

          }

          • 1

          信息

          ID
          443
          时间
          1000ms
          内存
          32MiB
          难度
          5
          标签
          递交数
          260
          已通过
          97
          上传者