Python2017/labs03/task01.py

31 lines
366 B
Python
Raw Normal View History

2017-12-02 15:40:31 +01:00
lista = [1, 2, 3]
a=id(lista)
b=id(lista)
if a == b:
print('Lista Immutable')
else:
print('Lista Mutable')
napis = 'Napis'
c=id(napis)
d=id(napis)
if c == d:
print('Napis Immutable')
else:
print('Napis Mutable')
liczba=23.34
e=id(liczba)
f=id(liczba)
if e == f:
print('Liczba Immutable')
else:
2017-12-02 15:43:44 +01:00
print('Liczba Mutable')
print('Koniec')