DataMuseum.dk

Presents historical artifacts from the history of:

DKUUG/EUUG Conference tapes

This is an automatic "excavation" of a thematic subset of
artifacts from Datamuseum.dk's BitArchive.

See our Wiki for more about DKUUG/EUUG Conference tapes

Excavated with: AutoArchaeologist - Free & Open Source Software.


top - download

⟦e07c6ab41⟧ TextFile

    Length: 402 (0x192)
    Types: TextFile
    Names: »sieve.p«

Derivation

└─⟦a0efdde77⟧ Bits:30001252 EUUGD11 Tape, 1987 Spring Conference Helsinki
    └─ ⟦this⟧ »EUUGD11/euug-87hel/sec1/prep/sieve.p« 

TextFile

c sieve benchmark in fortran

#include "prepmac.h"
: S		8190 ;
: WHILE(l)	begin
		while (l) ;

do limits [ (0, S) ]

	integer f(S+1), i, p, k, c, n

	do n = 1, 10
	   c = 0
	   f(#) = 1
[	   if ( f(#) != 0 ) then
	      p = # + # + 3
	      k = # + p
	      WHILE ( k <= S )
	         f(k) = 0
	         k = k + p
	      again
	      c = c + 1
	   end if
]
	enddo

	write(*,*) c, ' primes'

	stop
	end