QOJ.ac

QOJ

IDProblemSubmitterResultTimeMemoryLanguageFile sizeSubmit timeJudge time
#269719#5304. Money GameCarpe_DiemRE 0ms0kbC++20394b2023-11-29 21:56:262023-11-29 21:56:26

Judging History

你现在查看的是最新测评结果

  • [2023-11-29 21:56:26]
  • 评测
  • 测评结果:RE
  • 用时:0ms
  • 内存:0kb
  • [2023-11-29 21:56:26]
  • 提交

answer

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

int n;

void solve(){
    scanf("%d",&n);
    long long sum=0;
    for(int i=1;i<=n;i++){
        int u;
        scanf("%lld",&u);
        sum+=u;
    }

    double ans=(double)sum/(n+1);

    printf("%.7lf ",ans*2);
    for(int i=1;i<n;i++)printf("%.7lf ",ans);printf("\n");
}

int main(){

    solve();


    return 0;
}

Details

Tip: Click on the bar to expand more detailed information

Test #1:

score: 0
Runtime Error

input:

2
4 2

output:


result: