nefu 84 http://acm.nefu.edu.cn/test/problemshow.php?problem_id=84
摘要:
#includeusing namespace std;typedef long long inta;int extend_gcd(inta a,inta b,inta &x,inta &y,inta &gcd){ if(b==0) { x=1; y=0; gcd=a; } else { extend_gcd(b,a%b,x,y,gcd); int temp=x; x=y; y=temp-a/b*y; }}int gcd(int a,int b){ if(b==0) return a; ... 阅读全文
posted @ 2013-07-08 18:12
814jingqi的ACM
阅读(143)
评论(0)
推荐(0)
浙公网安备 33010602011771号