Submission #1093233

# Submission time Handle Problem Language Result Execution time Memory
1093233 2024-09-26T09:49:12 Z irmuun Balloons (CEOI11_bal) C++17
10 / 100
2000 ms 5108 KB
#include <bits/stdc++.h>

using namespace std;

#define ll long long
#define pb push_back
#define ff first
#define ss second
#define all(s) s.begin(),s.end()
#define rall(s) s.rbegin(),s.rend()

int main(){
    ios_base::sync_with_stdio(false); cin.tie(0); cout.tie(0);
    ll n;
    cin>>n;
    ll x[n+5],r[n+5];
    for(ll i=1;i<=n;i++){
        cin>>x[i]>>r[i];
    }
    double ans[n+5];
    ans[1]=(double)r[1];
    for(ll i=2;i<=n;i++){
        ans[i]=(double)r[i];
        for(ll j=1;j<n;j++){
            double mx=(x[i]-x[j])*(x[i]-x[j])/4.0/(double)ans[j];
            ans[i]=min(ans[i],mx);
        }
    }
    for(ll i=1;i<=n;i++){
        printf("%.5f\n",ans[i]);
    }
}
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB 2nd numbers differ - expected: '4.1670000000', found: '0.0000000000', error = '4.1670000000'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 348 KB 2 numbers
# Verdict Execution time Memory Grader output
1 Incorrect 3 ms 348 KB 3rd numbers differ - expected: '0.0420000000', found: '-9085397621989722308006065370057874654730002580482759879401445893696920841135011981615960750935705648237026698414991139075528536854475520585907218990428781941882880.0000000000', error = '9085397621989722308006065370057874654730002580482759879401445893696920841135011981615960750935705648237026698414991139075528536854475520585907218990428781941882880.0000000000'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 19 ms 604 KB 2nd numbers differ - expected: '122.0020000000', found: '-0.0000000000', error = '122.0020000000'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 623 ms 1676 KB 2nd numbers differ - expected: '212.0010000000', found: '-28188340039841679936559881423683584000.0000000000', error = '28188340039841679936559881423683584000.0000000000'
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2052 ms 1368 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2067 ms 2648 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2058 ms 2908 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2061 ms 3924 KB Time limit exceeded
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Execution timed out 2050 ms 5108 KB Time limit exceeded
2 Halted 0 ms 0 KB -