Ask Your Question

Wolan's profile - activity

2018-10-05 19:51:55 +0200 received badge  Student (source)
2018-10-05 19:49:14 +0200 asked a question test value of symbolic expression's operator

I need to define a boolean function is_pow that takes for argument a symbolic expression expr an that return True if and only if expr.operator is the builtin function pow. But I don'n know which the syntax to use:

Of course

def is_pow(expr):
 return expr.operator() ==  <built-in function pow>

doesn't work. Has someone the answer ? Thanks a lot.