+ 1

Function parameters

Hi everyone! Does anybody know how to get the parameters of built in functions through python itself rather than Google. I've already tried inspect.signature() and inspect.getfullargspec(), but they just don't work for built in functions.

13th Oct 2020, 5:41 PM
Michael
7 Respuestas
0
like if you import math and want to see all its methods and stuff? import math print(dir(math))
13th Oct 2020, 5:47 PM
Slick
Slick - avatar
0
Thanks Slick for your comment, but that's not what I'm looking for. It's like getting keyword arguments of functions e.g timedelta has days and weeks ad its keyword arguments, but if sb is not familiar with this function he can't get to know about these stuffs
13th Oct 2020, 5:51 PM
Michael
0
Yeah you got the point, but my problem is that this mehod doesn't work for built in functions, is there any way to solve it?
13th Oct 2020, 6:06 PM
Michael
0
for what specific one?
13th Oct 2020, 6:08 PM
Slick
Slick - avatar
0
For any built in function
13th Oct 2020, 7:23 PM
Michael
0
print the help then.
13th Oct 2020, 7:26 PM
Slick
Slick - avatar