def vigenere(text, custom_key):
encryption = (text, custom_key)
return encryption
Hi @mordonez
Call your function passing
text
andcustom_key
as the arguments. Store the return value of the function call in a variable calledencryption
.
Your code is defining a function
, not calling it.
Also, your code is assigning the arguments to a variable.
For this step, assign function call (with arguments) to the variable.
No need for the return
statement.
Happy coding
Hi @mordonez
For next time, describe the issue in your own words. Learning to communicate problems is a part of becoming a web developer.
Happy coding
hi @Teller
if i erase the return statement, it still say that “You should have an encryption variable.” my code doesn’t have the variable? or i should write it in other way?
Your function definition ends with the return statement.
Then later on, when you want to use the function, you call it.
Define the function:
def function(parameter):
code
return code
call the function:
function(argument)
hi @pkdvalis
i try calling it function, but says that i need call it vigenere. so when i change it continue with “You should have an encryption variable.” so i dont know if im not puting the variable or if i missing someting
Hi @mordonez
Use what @pkdvalis wrote above, regarding the difference between defining a function, and calling a function.
You just need to rearrange a few things to make the code into a function call assigned to a variable.
Happy coding
Don’t call it function. This was a generic example of syntax of how to define and call (run/use) a function.
This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.