結果
問題 |
No.1096 Range Sums
|
ユーザー |
👑 |
提出日時 | 2021-12-08 00:10:18 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
WA
|
実行時間 | - |
コード長 | 234 bytes |
コンパイル時間 | 519 ms |
コンパイル使用メモリ | 65,464 KB |
実行使用メモリ | 6,944 KB |
最終ジャッジ日時 | 2024-07-08 03:56:00 |
合計ジャッジ時間 | 1,372 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 7 WA * 5 |
ソースコード
#include <iostream> #include <vector> using namespace std; int main(){ long long ans = 0; int n;cin>>n; for(int i = 0; n > i; i++){ long long x;cin>>x; ans += (i+1)*(n-i)*x; } cout << ans << endl; }