I only have a side note about "geometry that is far from our universe".
in reply to Programming & real life
Actually this is what almost all high mathematics is about.
Topology, and most of all - algebra (not a calculation but algebra in its own) are very abstract and only come to our universe in their application side from time to time, most of the time having specualtions about many things inside them.
Alike, when your donut is extremely (infinitely) huge you will be very close to speculations in our 3D universe.
However IMHO teacher should not distract young people from further studying by frustrating them (like it was in your case) and forcing them studying what they do not want.
I fully agree it is much more interesting to have tasks and their bright solution applied in real life, so you will have fun solving them.
BTW what is programming Perl mostly is about - is having fun.
Courage, the Cowardly Dog