Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
96685 | 李佳璟 | 15求两个数的最大公约数 | C++ | Time Limit Exceeded | 1000 MS | 268 KB | 182 | 2024-11-09 11:52:03 |
#include<iostream> using namespace std; int main() { int a,b,y; cin>>a>>b; y=a%b; while(y !=0){ a=b; b=y; } cout<<b; return 0; }