两个互质的数不能够凑出来的最大的数是(a-1)*(b-1)-1
#include<bits/stdc++.h> using namespace std; typedef long long LL; int main() { LL a,b; cin>>a>>b; LL res=(a-1)*(b-1)-1; cout<<res; return 0; }
Using your lizikid universal account