我正在用Python编程,我想知道我是否可以测试我的代码中是否调用了函数
def example(): pass example() #Pseudocode: if example.has_been_called: print("foo bar")
我该怎么做?
python python-3.x
python ×1
python-3.x ×1