I want to have a function that I can call it with or without an argument, using another function to get the argument value in case it is missing.
I already tried this:
def GetValue():
...
def Process (value = GetValue):
...
I tried to call the function Process with Process() and Process(105) but it called the function GetValue either way.
Anything on the
defline is executed when the function is defined. You want to callGetValueinside theProcessfunction so that it’s only called when the condition is met for a specific argument value: