Run ID 作者 问题 语言 测评结果 分数 时间 内存 代码长度 提交时间
128664 Microsoft 求最大公约数和最小公倍数 C++ 解答错误 0 0 MS 252 KB 193 2024-01-26 08:24:54

Tests(0/3):


#include<bits/stdc++.h> using namespace std; int main() { int a,b,c; c=b; cin>>a>>b; int r=a%b; while(r!=0){ a=b; b=r; r=a%b; } cout<<b<<" "<<a*c/b; return 0; }


测评信息: