2019年8月30日

LightOJ - 1370 Bi-shoe and Phi-shoe 欧拉函数 题解

摘要: 题目: Bamboo Pole-vault is a massively popular sport in Xzhiland. And Master Phi-shoe is a very popular coach for his success. He needs some bamboos for 阅读全文

posted @ 2019-08-30 22:06 Caution_X 阅读(193) 评论(0) 推荐(0) 编辑

UVA 583 分解质因数

摘要: Webster defines prime as:prime (prim) n. [ME, fr. MF, fem. of prin first, L primus; akin to L prior] 1: first intime: original 2 a: having no factor 阅读全文

posted @ 2019-08-30 16:48 Caution_X 阅读(344) 评论(0) 推荐(0) 编辑

UVA 10699 Count the factors 题解

摘要: Time limit3000 msOSLinux Write a program, that computes the number of different prime factors in a positive integer.InputThe input tests will consist 阅读全文

posted @ 2019-08-30 14:27 Caution_X 阅读(214) 评论(0) 推荐(0) 编辑

POJ 1061 青蛙的约会 题解

摘要: 青蛙的约会 Time Limit: 1000MS Memory Limit: 10000K Total Submissions: 139755 Accepted: 31803 Description 两只青蛙在网上相识了,它们聊得很开心,于是觉得很有必要见一面。它们很高兴地发现它们住在同一条纬度线上 阅读全文

posted @ 2019-08-30 14:07 Caution_X 阅读(314) 评论(0) 推荐(0) 编辑

[模板]求解线性同余方程

摘要: 求解a*x = b (mod p) #include<bits/stdc++.h> using namespace std; int exgcd(int a,int b,int& x,int& y) { int d=a; if(b){ d=exgcd(b,a%b,y,x); y-=(a/b)*x; 阅读全文

posted @ 2019-08-30 13:03 Caution_X 阅读(205) 评论(0) 推荐(0) 编辑

导航