My nerdiest pun.
I wrote a python script to create a spiral matrix for any given size n. I decided to keep it fairly simple and just iterate from 0 to n squared while keeping track of direction… It turned out to be a lot of code though, had to worry about those corner cases! Get it? Corner cases?