1
0

replace mathblog.dk links with waybackmachine
All checks were successful
Build Docker and Deploy / Build Docker (push) Successful in 45s
Build Docker and Deploy / Deploy to Server (push) Successful in 19s

This commit is contained in:
2025-03-30 23:43:38 +02:00
parent be1c44ffc6
commit ba579dab23
8 changed files with 9 additions and 9 deletions

View File

@@ -2,12 +2,12 @@ Wow, so this is now officially my biggest (in terms of file size) befunge progra
The file has around ten megabyte. And probably also in terms of unique variables (26 variables plus two 2D-arrays)
The problem was also not that *befunge-compatible*.
My solution is pretty similar with the one from [MathBlog](http://www.mathblog.dk/project-euler-60-primes-concatenate/).
My solution is pretty similar with the one from [MathBlog](https://web.archive.org/web/20150407005005/http://www.mathblog.dk/project-euler-60-primes-concatenate/).
We generate primes from `1` to `3300` and save verified pairs in an Hashmap.
And when I say Hashmap I mean an *fucking* `3000x3000` array where every possible pair has an field (yay for befunge).
I had to use quite a few codesnippets from older project:
My standard [sieve of eratosthenes](https://en.wikipedia.org/wiki/Sieve_of_Eratosthenes), an implementation of the [Miller-Rabin primality test](https://en.wikipedia.org/wiki/Miller%E2%80%93Rabin_primality_test) and method to [concatenate two numbers](http://www.mathblog.dk/files/euler/Problem60.cs).
My standard [sieve of eratosthenes](https://en.wikipedia.org/wiki/Sieve_of_Eratosthenes), an implementation of the [Miller-Rabin primality test](https://en.wikipedia.org/wiki/Miller%E2%80%93Rabin_primality_test) and method to [concatenate two numbers](https://web.archive.org/web/20150103211935/http://www.mathblog.dk/files/euler/Problem60.cs).
In the end is to say that in befunge the program size is normally an good indicator for the runtime (not really, but its kinda correct for all my programs).
So as you probably guessed this program takes a pretty loooooong time to complete.