提交时间:2024-01-25 09:38:08

运行 ID: 127598

#include <bits/stdc++.h> using namespace std; int main (){ ios::sync_with_stdio(false); cin.tie(0); int n; while (cin >> n){ cout << (pow(2, n - 1) + 1) % n; } return 0; }