inserts integers 2 to
n
into
candidates
for (i=2;i<=n;i++)
insert(i,candidates);