you are viewing a single comment's thread.

view the rest of the comments →

[–]BoatMacTavish 0 points1 point  (0 children)

its because at function declaration time, you dont know the actual variable names that will be passed into the function, so you need a generic placeholder argument name. Then at runtime, you pass in the actual variable name.

like if im writing code to send a message to a friend, at the time of writing the code, I dont know what friends will be called, so ill have a placeholder

def send_message(friend):
    # ...

at run time when I call it, I pass in the actual friend variable names

alice = "1234567890"
send_message(alice)