結果
| 問題 |
No.3115 One Power One Kill
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2025-04-20 13:27:52 |
| 言語 | C++17 (gcc 13.3.0 + boost 1.87.0) |
| 結果 |
AC
|
| 実行時間 | 54 ms / 2,000 ms |
| コード長 | 778 bytes |
| コンパイル時間 | 2,006 ms |
| コンパイル使用メモリ | 192,408 KB |
| 実行使用メモリ | 25,996 KB |
| 平均クエリ数 | 2.00 |
| 最終ジャッジ日時 | 2025-04-20 13:27:57 |
| 合計ジャッジ時間 | 4,728 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 20 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
int main() {
ios::sync_with_stdio(false);
cin.tie(nullptr);
const long long A = 180; //指数
const long long B = 100; //法
cout << A << ' ' << B << endl; // ①
cout.flush();
long long K; // ②
if (!(cin >> K)) return 0;
bool div2 = (K % 2 == 0);
bool div5 = (K % 5 == 0);
long long ans; // ③
if (div2 && div5) ans = 0; // 2 と 5 の両方で割れる
else if (div2) ans = 76; // 2 で割れて 5 では割れない
else if (div5) ans = 25; // 5 で割れて 2 では割れない
else ans = 1; // どちらでも割れない
cout << ans << endl;
cout.flush();
return 0;
}