Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.c++ > #119140

Re: Sieve of Erastosthenes optimized to the max

From Ben Bacarisse <ben@bsb.me.uk>
Newsgroups comp.lang.c++
Subject Re: Sieve of Erastosthenes optimized to the max
Date 2024-05-16 21:40 +0100
Organization A noiseless patient Spider
Message-ID <87ttixij8d.fsf@bsb.me.uk> (permalink)
References (16 earlier) <utoh9d$6lrr$1@raubtier-asyl.eternal-september.org> <utq0ag$hvrl$3@dont-email.me> <utq0os$ibqn$1@raubtier-asyl.eternal-september.org> <utq11p$icmm$1@dont-email.me> <v25c87$1ld9m$1@dont-email.me>

Show all headers | View raw


Vir Campestris <vir.campestris@invalid.invalid> writes:
...
> When I compared the output there were differences. Specifically your
> program claimed that these numbers
>
> 66049,67591,69133,69647,71189,72217,72731,75301,78899,79927,80441,81469,85067,86609,89179,
> 89693,90721,92263,94319,95861,97403,98431,99973,102029,103057,105113,107683,108197,110767,
> 111281,112823,113851,115393,117449,118477,118991,120019,123103,125159,126187,128243,129271,
> 130813,133897,134411,139037,140579,143149,144691,146233,146747,148289,150859,152401,153943,
> 154457,155999,157541,158569,159083,162167,164737,165251,166279,167821,169363,169877,172961,
> 173989,175531,177587,180157,182213,184783,186839,188381,189923,190951,193007,194549,195577,
> 197633,198661,202259,204829,207913,208427,210997,211511,212539,213053,215623,219221,220249,
> 220763,221791,225389,226417,226931,227959,233099,234127,236183,238753,240809,241837,243379,
> 244921,248519,249547,251089,252631,254687,256229,259313,260341,261883,262397,264967,265481,
> 267023,269593,270107,272677,273191,274733,279359,280387,280901,281929,283471,285013,287069,
> 288611,290153,295807,296321,298891,300947,303517,305059,306601,308657,311741,312769,314311,
> 315853
>
> are all prime. They aren't. The first one is 257 squared, and the others
> all have factors too.

In fact they are /all/ 257 times some prime.  That must be a big clue as
to where the bug is...

-- 
Ben.

Back to comp.lang.c++ | Previous | NextPrevious in thread | Next in thread | Find similar


Thread

Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-05-16 17:28 +0100
  Re: Sieve of Erastosthenes optimized to the max Ben Bacarisse <ben@bsb.me.uk> - 2024-05-16 21:40 +0100
  Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-05-21 19:06 -0700
    Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-05-30 12:32 +0100
      Re: Sieve of Erastosthenes optimized to the max Bonita Montero <Bonita.Montero@gmail.com> - 2024-05-30 14:17 +0200
      Re: Sieve of Erastosthenes optimized to the max Paavo Helde <eesnimi@osa.pri.ee> - 2024-05-30 19:55 +0300
        Re: Sieve of Erastosthenes optimized to the max Bonita Montero <Bonita.Montero@gmail.com> - 2024-05-31 10:17 +0200
          Re: Sieve of Erastosthenes optimized to the max Paavo Helde <eesnimi@osa.pri.ee> - 2024-05-31 20:52 +0300
      Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-05-30 22:17 -0700
        Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-06-01 21:07 +0100
          Re: Sieve of Erastosthenes optimized to the max Richard Damon <richard@damon-family.org> - 2024-06-01 20:43 -0400
          Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-06-02 03:23 -0700
            Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-06-02 19:50 -0700
              Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-06-18 20:56 +0100
                Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-06-18 17:34 -0700
                Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-06-30 21:47 +0100
                Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-07-01 23:20 -0700
                Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-07-02 21:24 +0100
                Re: Sieve of Erastosthenes optimized to the max Vir Campestris <vir.campestris@invalid.invalid> - 2024-07-03 11:25 +0100
                Re: Sieve of Erastosthenes optimized to the max Tim Rentsch <tr.17687@z991.linuxsc.com> - 2024-07-15 06:15 -0700

csiph-web