Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
103747 张黄源 公约数问题 C++ Wrong Answer 119 MS 268 KB 269 2024-12-29 15:06:28

Tests(1/10):


Code:

#include<bits/stdc++.h> using namespace std; long long jc(int bcs,int cs){ int max; for(int i=1;i<<cs;i++){ if(bcs%i==0&&cs%i==0){ max=i; } } return max; } int main() { long long a,b; cin>>a>>b; long long s=jc(a,b); cout<<s; return 0; }


Run Info:

------Input------
4140 3864
------Answer-----
276
------Your output-----
138