Article of the week

Bash recursion examples - part 1

Bash recursion examples - part 1

15 Jan 2017 16:58:45


Some recursive Maths functions written in BASH.


Read full article »

Recent articles

A troubled relationship between PHP and large integers

09 Feb 2020 23:23:46

A troubled relationship between PHP and large integers

Suppose, that you need to compute 25! in PHP. It is a fairly large number. PHP will tell you that it is 1.551121004E+25, nice and short. No surprises here. Let's look under the hood, though. Sometimes you need, for example to do something with each digit of the number. So, ...

Read more »

Longest Collatz sequence in PHP

08 Feb 2020 23:30:22

Longest Collatz sequence in PHP

This article is a result of a fairly well known computer programming problem I came across online some time ago. Essence of the problem was about finding the longest Collatz sequence, that is the largest number of terms for a number less than N, with N being 1 000 000. For ...

Read more »

Number of primes less than N

04 Feb 2020 20:33:40

Number of primes less than N

In this article I look at how to find all prime numbers below a certain positive number N, as well as their sum. We do not know how primes are distributed. There is no function, which reliably finds all primes less then a large natural number. However, we do known an algorithm, ...

Read more »

Symmetric and asymmetric - key encryption with gpg and gpg-zip

29 Jun 2018 19:38:09

Symmetric and asymmetric - key encryption with gpg and gpg-zip

We have stored more and more data, sometimes logins, passwords and whole databases, by popular cloud storage services today. On one hand, keeping files with them seems like a good idea. You get access to your files on demand, on any device you connect to service with, from ...

Read more »