Python source code for math exponent function?
问题 When I do math computation in Python which library are we using. E.g. >>> 2**0.5 1.4142135623730951 How can I find the source code that was used? Is this just the math.pow() function? Unfortunately, inspect.getsource(pow) returns a kind of error. Searching on Github narrows it down to 13 possible files. And I don't fully understand how cPython is constructed. /*[clinic input] math.pow x: double y: double / Return x**y (x to the power of y). [clinic start generated code]*/ static PyObject *