In Python, arguments are passed to functions using pass-by-object-reference , a hybrid approach where the behavior depends on the object’s mutability. For mutable objects (e.g., lists, dictionaries), functions can modify the object directly, as the reference points to the same memory location. For immutable objects (e.g., integers, strings), any attempt to modify them results in a new object being created, leaving the original object unchanged. For example: def modify_list(lst): lst.append(4) my_list = [1, 2, 3] modify_list(my_list) print(my_list) # Output: [1, 2, 3, 4] In the case of immutables: def modify_int(x): x += 1 num = 5 modify_int(num) print(num) # Output: 5 This illustrates that Python’s approach is neither traditional pass-by-value nor pass-by-reference. Why Other Options Are Incorrect:
Which regulatory body has introduced an advanced mode of bank account verification of subscribers through PAN-PRAN-UPI?
In which year were two additional Election Commissioners appointed to the Election Commission of India?
Which two navies participated in the annual bilateral maritime exercise Konkan 2023 held off the Konkan coast in the Arabian Sea?
The __________ has signed an agreement with Chinese smart devices maker Oppo's Indian arm to strengthen the research and development of the NavIC messag...
JIMEX Maritime Exercise 2023 was organized between the Navy of India and which country?
What is the primary category under which the Defence Ministry is procuring weapons systems and platforms, giving a boost to 'Aatmanirbhar Bharat' in the...
What is the primary objective of the Multinational Military Exercise KHAAN QUEST in which the Indian Army is participating?
What is the primary aim of the Memorandum of Understanding (MoU) between the Department of Social Justice and Empowerment and Gayatri Parivar?
Recently India and which Country has signed a pact to promote Palm oil?
__________ and PhonePe have collaborated to provide a range of inclusive car and bike insurance products directly to users through the PhonePe platform....