結果
問題 |
No.1674 Introduction to XOR
|
ユーザー |
![]() |
提出日時 | 2022-09-05 11:58:30 |
言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
結果 |
AC
|
実行時間 | 2 ms / 1,000 ms |
コード長 | 418 bytes |
コンパイル時間 | 700 ms |
コンパイル使用メモリ | 70,152 KB |
実行使用メモリ | 6,820 KB |
最終ジャッジ日時 | 2024-11-20 11:15:13 |
合計ジャッジ時間 | 1,436 ms |
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 21 |
ソースコード
#include <iostream> #include <vector> using namespace std; using ll = long long; int main(){ int n; cin >> n; vector<ll> a(n); for(auto &it: a) cin >> it; for(int i = 0; i < 62; i++){ bool isok = true; for(auto &it: a){ if((it >> i) & 1) isok = false; } if(isok){ cout << (1LL << i) << endl; return 0; } } return 0; }