Squangular numbers

Simon has created a Python program that looks for “squangular” numbers.

36 is both a square number (6×6 square of things makes 36 things) and a triangular number (8×8 triangle of things makes 36 things). I call this kind of numbers squangular. Squangular numbers are both square and triangular.

Squangular numbers are rare, like the next squangular number is 1225. The next one is 41616, then 1413271, then 48024900, and after that I didn’t bother checking.

Link to code here: https://repl.it/@simontiger/SquangularNumbers#main.py

Screenshot of the code with the results: six squangular numbers found.
Simon first created the program in Visual Studio but that code didn’t work.
The formula for triangular root.

Btw, I totally didn’t make up the term “squangular”.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s