結果
| 問題 | No.820 Power of Two |
| コンテスト | |
| ユーザー |
Yut176
|
| 提出日時 | 2019-05-18 02:52:24 |
| 言語 | C++14 (gcc 15.3.0 + boost 1.92.0 + ACL) |
| 結果 |
AC
不安定
|
| 実行時間 | 1 ms / 2,000 ms |
| + 376µs | |
| コード長 | 426 bytes |
| 記録 | |
| コンパイル時間 | 424 ms |
| コンパイル使用メモリ | 97,380 KB |
| 実行使用メモリ | 6,272 KB |
| 最終ジャッジ日時 | 2026-08-29 08:18:28 |
| 合計ジャッジ時間 | 1,348 ms |
|
ジャッジサーバーID (参考情報) |
judge3_1 / judge2_0 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 10 |
ソースコード
#include<iostream>
#include<algorithm>
#include<cstdio>
#include<cstdlib>
#include<vector>
#include<string>
#include<sstream>
#include<cmath>
#include<numeric>
#include<map>
#include<stack>
#include<queue>
using namespace std;
int main(void) {
int n, k; cin >> n >> k;
if (k > n) {
cout << 0 << endl;
return 0;
}
int x = 1;
for(int i=0; i<n-k; i++) x *= 2;
cout << x << endl;
return 0;
}
// EOF
Yut176