Typescript Reduce Sum Python Function Overloading Syntax