+ 2
One more problem in Create a FUNCTION. How to create a function,pass parameter and return value? Please tell me
I am learning PYTHON programming language and I just stuck in FUNCTION.
1 Resposta
+ 2
def my_function_name (parameter1, parameter2):
print("You passed", parameter1, "as the first parameter, and", parameter2, "as the second parameter.")
return parameter1 + parameter2
x = my_function_name(2,5) # x is assigned the value given in the function's return line.
print(x) #prints 7