python - Read the end of an IP Adress -




i last part of ip address , save it. think it's simple don't know how to. so, can read ip address of variable ip_adrr. example, if print in code :

print ip_adrr 

i 192.168.1.25 want 25, how possible it?

ip_adrr.split('.')[-1]

if ip_adrr not string cast string str(ip_adrr)





wiki

Comments

Popular posts from this blog

Asterisk AGI Python Script to Dialplan does not work -

kotlin - Out-projected type in generic interface prohibits the use of metod with generic parameter -

python - Read npy file directly from S3 StreamingBody -