in my institute i was told that every variable in python has it's own memory address and memory address in each variable is different.They proved it by using id() command , they showed us
>>>a=10
>>>b=20
>>>id(a)
94349304104992
>>>id(b)
94349304105312
by showing this statement they proved us how both the memory location are different.
then i was trying the same thing with my linux terminal and got some weird answer when i tried....
>>>id(999)
139978570234704
>>>id(10001)
139978570234704
>>>id(9999)
139978570234704
>>>id(100001)
139978570234704
>>>id(99999)
139978570234704
>>>id(1000001)
139978570234704
>>>id(999999)
139978570234704
>>>id(10000001)
139978570234704
after trying all this i found that this all numbers i pointing toward same location and i can not understand why this is happening only with this kind of number
beside this when i tried the same thing on windows cmd it worked fine. Every values got allocated to the different location