Thanks for the article, very clear. I also wrote an article on some of the maths theorems behind the RSA cryptosystem: https://fmarthoz.medium.com/the-elegant-maths-behind-the-rsa-encryption-ab92a5d8f3f7#4ec8-28bcfff0baeb if anyone wants to dig a bit deeper on why it works.