Question: Given the following code: val = 9 def subtract _ one ( num ) : num = num - 1 print ( ' inside function:
Given the following code:
val
def subtractonenum:
num num
printinside function: strnum
printbefore function call: strval
subtractoneval
printafter function call: strval
The code will print out:
before function call:
inside function:
after function call:
Why does the value of val not become after the function call? Select all that apply.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
