When declared an integer to a variable, both the integer and variable returns the same id value. But, in case of float, it returns a different id value. What is the reason behind it?
As below,
a=10
>>> id(a)
48068132
>>> id(10)
48068132
>>> b=10.1
>>> id(b)
50912320
>>> id(10.1)
50912336