結果
| 問題 | No.378 名声値を稼ごう |
| コンテスト | |
| ユーザー |
nninjinn00
|
| 提出日時 | 2017-02-11 16:33:06 |
| 言語 | C++11 (gcc 15.2.0 + boost 1.89.0) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 159 bytes |
| 記録 | |
| コンパイル時間 | 543 ms |
| コンパイル使用メモリ | 68,984 KB |
| 実行使用メモリ | 9,856 KB |
| 最終ジャッジ日時 | 2026-06-03 10:46:11 |
| 合計ジャッジ時間 | 7,276 ms |
|
ジャッジサーバーID (参考情報) |
judge3_0 / judge1_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | -- * 1 |
| other | TLE * 1 -- * 4 |
コンパイルメッセージ
main.cpp: In function 'int main()':
main.cpp:10:20: warning: 'n2' may be used uninitialized [-Wmaybe-uninitialized]
10 | cout << n1-n2 << endl;
| ^~
main.cpp:5:30: note: 'n2' was declared here
5 | long long int n, n1, n2;
| ^~
ソースコード
#include <iostream>
using namespace std;
int main() {
long long int n, n1, n2;
cin >> n;
n1 = n * 2;
while(n!=0)
n2 += n / 2;
cout << n1-n2 << endl;
}
nninjinn00