結果 : how to call a function inside an if statement python