How are arguments passed by value or by reference in Python?
Answer Posted / nashiinformaticssolutions
In Python, arguments are passed by assignment, meaning that the reference to an object is passed to the function. Immutable types (like integers, strings, tuples) behave like "pass-by-value" because their content cannot be modified, while mutable types (like lists, dictionaries) behave like "pass-by-reference" because their content can be modified.
| Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
Why python is fast?
What are closures in python?
Is there a null in python?
Does apple use python?
How do you use return in python?
Why do we use uuid?
Why is python 2 still used?
What is pytables?
So, then, what is the global keyword?
What is form feed in python?
What is different between class and object?
Can we develop a web application using Python
What is the use of negative indexes?
State and explain about strings?
How do you create a list which is a reverse version on another list in python?