結果
| 問題 |
No.1134 Deviation Score Ⅱ
|
| ユーザー |
|
| 提出日時 | 2020-07-29 18:35:26 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 22 ms / 2,000 ms |
| コード長 | 269 bytes |
| コンパイル時間 | 699 ms |
| コンパイル使用メモリ | 67,276 KB |
| 実行使用メモリ | 6,944 KB |
| 最終ジャッジ日時 | 2024-06-29 21:49:11 |
| 合計ジャッジ時間 | 1,756 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 1 |
| other | AC * 27 |
コンパイルメッセージ
main.cpp:7:1: warning: ISO C++ forbids declaration of 'main' with no type [-Wreturn-type]
7 | main()
| ^~~~
ソースコード
#include<iostream>
#include<cmath>
using namespace std;
int N;
int x[1<<17];
int M;
main()
{
cin>>N;
long s2=0,s=0;
for(int i=0;i<N;i++)
{
cin>>x[i];
s+=x[i];
s2+=x[i]*x[i];
}
cin>>M;M--;
cout<<(N*s2!=s*s?(int)(50+10*(N*x[M]-s)/sqrt(N*s2-s*s)):50)<<endl;
}