結果
| 問題 |
No.939 and or
|
| コンテスト | |
| ユーザー |
👑 |
| 提出日時 | 2020-03-13 21:38:09 |
| 言語 | C++14 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 340 bytes |
| コンパイル時間 | 516 ms |
| コンパイル使用メモリ | 65,732 KB |
| 実行使用メモリ | 6,820 KB |
| 最終ジャッジ日時 | 2024-11-22 19:51:32 |
| 合計ジャッジ時間 | 1,556 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge3 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 2 |
| other | AC * 25 WA * 5 |
ソースコード
#include <iostream>
#include <bitset>
//にゃー
using namespace std;
int main(){
int a,b;cin>>a>>b;
bitset<32> A(a),B(b);
//cout << A << endl;
//cout << B << endl;
long long z = 1;
for(int i = 0; 32 > i; i++){
if(A[i] && !B[i]){
cout << 0 << endl;
return 0;
}else if(!A[i] && B[i]){
z*=2;
}
}
cout << z/2 << endl;
}