Printing some primes (Hard)

Problem Name:
Printing some primes (Hard)
Site:Spoj
Links:
Tags:
Problem setters: