Skip to content Skip to sidebar Skip to footer
Showing posts with the label Reference

If In Python I Put A List Inside A Tuple, Can I Safely Change The Contents Of That List?

The value inside the tuple is simply a reference to a list, and if I change the values in the list … Read more If In Python I Put A List Inside A Tuple, Can I Safely Change The Contents Of That List?

Compare Two Same Strings But Get Different Results In IDLE

I'm using python 2.7.2 with built-in IDLE on windows 7 x64, and found a very strange thing: >… Read more Compare Two Same Strings But Get Different Results In IDLE

Is This A Bug? Variables Are Identical References To The Same String In This Example (Python)

This is for Python 2.6. I could not figure out why a and b are identical: >>> a = 'som… Read more Is This A Bug? Variables Are Identical References To The Same String In This Example (Python)