Food for thought: reza=[] rimon=[] and reza=rimon=[] what are the differences? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
0

Food for thought: reza=[] rimon=[] and reza=rimon=[] what are the differences?

22nd Dec 2018, 12:30 PM
Emily bunt
Emily bunt - avatar
3 Answers
+ 1
The first two represent empty lists.. The last one "reza" is assigned the value of "rimon" which is an empty list...
22nd Dec 2018, 12:37 PM
Mensch
Mensch - avatar
+ 1
The first case represents two different lists. In the second one two variables point to the same list. Just try this code, to see the difference: https://code.sololearn.com/chfKev558Zcx/?ref=app
22nd Dec 2018, 12:55 PM
portpass
+ 1
Nice one! Please always remember that the Q&A section is reserved for programming related questions and answers, so if just want to post food for thought, your activity feed is a perfect place for that! Let's keep the Q&A section clean! Thank you! 😊
22nd Dec 2018, 1:18 PM
dρlυѕρlυѕ
dρlυѕρlυѕ - avatar