与‘数论-筛法’有关的日志

poj3292

maksyuki 发表于 oj 分类,标签:
0
poj3292

Semi-prime H-numbers

An H-number is a positive number which is one more than a multiple of four: 1, 5, 9, 13, 17, 21,... are the H-numbers. For this problem we pretend that these are the only numbers. The H-numbers are closed under multiplication.T >>继续阅读

poj2689

maksyuki 发表于 oj 分类,标签:
0
poj2689

Prime Distance

The branch of mathematics called number theory is about properties of numbers. One of the areas that has captured the interest of number theoreticians for thousands of years is the question of primality >>继续阅读

hdu2521

maksyuki 发表于 oj 分类,标签:
0
hdu2521

反素数

Problem Description

反素数就是满足对于任意i(0<i<x),都有g(i)<g(x),(g(x)是x的因子个数),则x为一个反素数。现在给你一个整数区间[a,b],请你求出该区间的x使g(x)最大。

Input

第一行输入n,接下来n行测试数据 >>继续阅读

hdu2098

maksyuki 发表于 oj 分类,标签:
0
hdu2098

分拆素数和

Problem Description

把一个偶数拆成两个不同素数的和,有几种拆法呢?

Input

输入包含一些正的偶数,其值不会超过10000,个数不会超过500,若遇0,则结束。 >>继续阅读

uva10533

maksyuki 发表于 oj 分类,标签:
0
uva10533

Digit Primes

A prime number is a positive number, which is divisible by exactly two different integers. A digit prime is a prime number whose sum of digits is also prime. For example the prime number 41 is a digit prime

because 4+1=5 and 5 is a p >>继续阅读

uva10168

maksyuki 发表于 oj 分类,标签:
0
uva10168

Euler proved in one of his classic theorems that prime numbers are infinite in number. But can every number be expressed as a summation of four positive primes? I don’t know the answer. May be you can help!!! I want your solution to be very efficient >>继续阅读