June 2018
Intermediate to advanced
294 pages
7h 5m
English
Tuples are similar to lists, but they're read only. I rarely use them, but they exist in Python, and you need to be aware of their existence:
ips = ('1.1.1.1','2.2.2.2')
ips = ('1.1.1.1','2.2.2.2')# Print the first IP addressips[0]
ips = ('1.1.1.1','2.2.2.2')# Print the length of the ips list which is 2 in this case:print len(ips)
Read now
Unlock full access