唯一分解定理
文章平均质量分 51
wwt9b15bs
这个作者很懒,什么都没留下…
展开
-
【题解】UVA10375 组合数+线性筛+唯一分解定理
题目链接 线性筛出10000以内素数表,求出唯一分解式中各个素数的指数 #include<cstdio> #include<cstring> #include<cmath> #define _rep(i,a,b) for(int i=(a);i<=(b);i++) #define _for(i,a,b) for(int i=(a);i&原创 2018-08-12 09:14:13 · 199 阅读 · 0 评论 -
【题解】LightOJ1236 Pairs Forming LCM 唯一分解定理+线性筛
题目链接 Input Input starts with an integer T (≤ 200), denoting the number of test cases. Each case starts with a line containing an integer n (1 ≤ n ≤ 1014). Output For each case, print the ca...原创 2018-09-17 09:23:18 · 194 阅读 · 0 评论 -
【题解】洛谷P1463(同bzoj1053/LibreOJ10203)[POI2002][HAOI2007]反素数 唯一分解定理+dfs
题目链接 题目描述 对于任何正整数x,其约数的个数记作g(x)。例如g(1)=1、g(6)=4。 如果某个正整数x满足:g(x)>g(i) 0 < i < x,则称x为反质数。例如,整数1,2,4,6等都是反质数。 现在给定一个数N,你能求出不超过N的最大的反质数么? 输入输出格式 输入格式: 一个数N(1<=N&am原创 2018-09-11 13:37:27 · 253 阅读 · 0 评论 -
【题解】LightOJ1220 Mysterious Bacteria 线性筛+唯一分解定理+最大公约数
Description Dr. Mob has just discovered a Deathly Bacteria. He named it RC-01. RC-01 has a very strange reproduction system. RC-01 lives exactly x days. Now RC-01 produces exactly p new deadly Bacter...原创 2018-09-15 06:35:01 · 158 阅读 · 0 评论