A number is an   attractive number   if the number of its prime factors (whether distinct or not) is also prime.



Example

The number   20,   whose prime decomposition is   2 × 2 × 5,   is an   attractive number   because the number of its prime factors   (3)   is also prime.



Task

Show sequence items up to   120.



Reference

   The OEIS entry:   A063989: Numbers with a prime number of prime divisors.


from sympy import sieve # library for primes
 
def get_pfct(n): 
	i = 2; factors = []
	while i * i <= n:
		if n % i:
			i += 1
		else:
			n //= i
			factors.append(i)
	if n > 1:
		factors.append(n)
	return len(factors) 
 
sieve.extend(110) # first 110 primes...
primes=sieve._list
 
pool=[]
 
for each in xrange(0,121):
	pool.append(get_pfct(each))
 
for i,each in enumerate(pool):
	if each in primes:
		print i,