Mathspp Blog

342 391,958 32,910
articles words lines of code

When will these two clocks synchronise again?

This article shows how to do base conversions in Python with the built-in int, how to write integer literals in other bases, and how to do base conversions in general.

The built-in function max in Python is broken and this article explains why, drawing parallels with other programming and mathematics concepts.

How can an infinite number of mathematicians figure out their own hat colours?

This article shows how to use the Python built-in divmod for unit conversions.

Today I learned that Python and other programming languages have negative zero, -0.0.

Create a zooming animation from first principles in Python. In 5 minutes. Kind of.

Create animations from first principles and morph between different figures with Python. In 5 minutes. Kind of.

Today I learned how to draw a Bézier curve with the De Casteljau's algorithm.

In this introductory tutorial, you will build a recurrent neural network (RNN) with PyTorch.

Go through the complete code for a Python project that consists in finding similar photographs in a folder. This tutorial will make use of classical techniques and is suitable for beginners.

Can you prove that there are arbitrarily many primes in arbitrarily big intervals?

Today I learned what precision Python floats have.

Today I (re)learned Heron's formula to compute the area of a triangle from its three sides.

Can you align all of the coins on the right edge of the board?

Three mathematicians discuss a beautiful flower garden and the coloured flowers within.

Two realtors discuss who's netting the award for highest average commission, but it isn't clear who the winner is...

How can you swap the coloured pegs if they can only march forward?

Please help me identify these 100 light bulbs by turning ON and OFF their switches.

We discuss the look-and-say sequence, its behaviour, variations of it, and a Python implementation.