結果

問題 No.1047 Zero (Novice)
ユーザー Haar
提出日時 2020-05-08 21:33:52
言語 C++17
(gcc 13.3.0 + boost 1.87.0)
結果
AC  
実行時間 4 ms / 2,000 ms
コード長 203 bytes
コンパイル時間 2,626 ms
コンパイル使用メモリ 190,632 KB
最終ジャッジ日時 2025-01-10 08:13:57
ジャッジサーバーID
(参考情報)
judge1 / judge3
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 17
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>

int main(){
  int64_t a, b; std::cin >> a >> b;

  int ans = -1;

  if(b == 0){
    ans = 1;
  }else if(a == -1){
    ans = 2;
  }
  
  std::cout << ans << "\n";

  return 0;
}
0