random cover of a range

Simen Kjaeraas simen.kjaras at gmail.com
Fri Feb 13 11:53:11 PST 2009


On Fri, 13 Feb 2009 15:23:07 +0100, Andrei Alexandrescu <SeeWebsiteForEmail at erdani.org> wrote:

> 1. Factor m into primes. Obtain arrays p[], the prime factors, and w[],  
> their powers. For example, say m = 125, then p[] = [ 3, 5 ] and w[] = [  
> 1, 2 ].

You meant for m = 75, right? Otherwise, p[] = [ 5 ] and w[] = [ 3 ].

--
Simen



More information about the Digitalmars-d mailing list