Changes

Jump to: navigation, search

OPS435 Python Lab 3

21 bytes removed, 09:10, 2 June 2017
PART 2 - Providing Functions With Arguments
ipython3
</source>When passing arguments up to functions, you MUST contain data such as '''strings''', '''numbers''', or '''variable names''' within '''brackets''' immediately following the function name.<br><br>'''NOTE:''' Normally, when a function is declared that accepts arguments, those '''arguments must be declared''' (using variable names). Those declared variable names are then used within the function for processing. Also, when you call a function with arguments, the number of arguments passed up to the function must correspond (match) the number of arguments that were specified in the function declaration.<br><br>
:#Issue Enter the following from the ipython shell to declare a the function called '''square()''':<source>
def square(number):
return number ** 2
13,420
edits

Navigation menu