Reference Or Value pass in python

Preface


(1)Pass/call-by-Reference OR Pass-by Value also exists in Python(like:Python2.7);

(2)Commonly,if such immutable type arguments as Integers,Strings or tuples are passed to a functions , the passing acts like pass-by-call. In other words, callee(被調用者) functions can not change value of that kind of arguments passed by caller(調用者) ones. While situation is different when mutable type ones like list or dict are passed.

發佈了20 篇原創文章 · 獲贊 1 · 訪問量 5369
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章