I have a Ring R which I made and a method to return the zero element of that ring.
I want to be able to type R(0)
and have it return the zero element.
I have tried, and it works if I call the method directly, but not if I use R(0). Any tips?
class MyRing(Ring): .... def _zero_element(self): return ......