I'm studying Python
and in these studies I ended up with something curious.
> False = True
#Imprime: True
> print(False)
#Imprime: True
> False = bool(0)
> print(False)
#Imprime: False
That is, I was able to rewrite the value of False
by giving it the value of True
.
In languages such as javascript
or PHP
it is not possible to do this reassignment, because False
is a language constructor or even a constant.
Why can not Python
do this? How is False
treated in Python
? As a variable?