"link" 给定整数N,求1 include using namespace std; const int fuck = 10000000; int prime[10000010], tot; bool vis[10000010]; int mu[10000010], sum[10000010]; ...
分类:
其他好文 时间:
2019-01-20 20:06:53
阅读次数:
250
https://mp.weixin.qq.com/s/CbBWdTlc_DESlUzd8KFcSg 介绍Term类各方法的实现。 ?? 1. prime 表示一个项是否是质项,即这个项是否被其他项包含。如项AB包含项ABC。 2. covers ?? this covers x,即项this包含项x ...
分类:
其他好文 时间:
2019-01-20 16:01:56
阅读次数:
166
``` Write a program to check whether a given number is an ugly number`. Ugly numbers are positive numbers whose prime factors only include 2, 3, 5. Fo ...
分类:
其他好文 时间:
2019-01-18 10:19:24
阅读次数:
181
prime_list=[2] def is_prime(num): i=0 n=prime_list[i] while num//n>=n: if num%n==0: return False i+=1 n = prime_list[i] return True def get_prime... ...
分类:
其他好文 时间:
2019-01-17 12:49:30
阅读次数:
180
题意:参考https://blog.csdn.net/lyy289065406/article/details/6648537 一个H-number是所有的模四余一的数。 如果一个H-number是H-primes 当且仅当它的因数只有1和它本身(除1外)。 一个H-number是H-semi-pr ...
分类:
其他好文 时间:
2019-01-16 22:56:30
阅读次数:
229
题意:给一个数 可以写出多少种 连续素数的合 思路:直接线性筛 筛素数 暴力找就行 (素数到n/2就可以停下了,优化一个常数) 其中:线性筛的证明参考:https://blog.csdn.net/nk_test/article/details/46242401 https://blog.csdn.n ...
分类:
其他好文 时间:
2019-01-16 22:47:07
阅读次数:
123
1、查看和设置物理机硬件时间 查看硬件时间# hwclock --show或# clock --show 设置硬件时间# hwclock --set --date=”01/14/19 10:19″(月/日/年 时:分:秒) 2、物理机系统时间和硬件时间的同步 硬件时间与系统时间同步: # hwclo ...
分类:
系统相关 时间:
2019-01-14 15:58:44
阅读次数:
312
calc() = calc(四则运算) 英文单词calculate(计算)的缩写 需要注意的是,运算符前后都需要保留一个空格,例如:width: calc(100% 10px); calc()函数支持 "+", " ", " ", "/" 运算; calc()函数使用标准的数学运算优先级规则; 兼容 ...
分类:
Web程序 时间:
2019-01-14 14:37:31
阅读次数:
189
题目描述 Output the k th prime number. 输入描述: k≤10000 输出描述: The k th prime number. include using namespace std; bool is_primer(int n){ for(int i = 2; i i k ...
分类:
其他好文 时间:
2019-01-13 18:03:34
阅读次数:
174
原文链接:https://oldpan.me/archives/how to calculate gpu memory 前言 亲,显存炸了,你的显卡快冒烟了! torch.FatalError: cuda runtime error (2) : out of memory at /opt/conda ...
分类:
其他好文 时间:
2019-01-13 16:08:08
阅读次数:
550