Basic getaddrinfo() basic example : Address Info « Network « Python






Basic getaddrinfo() basic example

Basic getaddrinfo() basic example
import sys, socket

result = socket.getaddrinfo("192.1.1.100", None)
print result[0][4]

print result

           
       








Related examples in the same category

1.Takes a host name on the command like and prints all resulting matches for it.Takes a host name on the command like and prints all resulting matches for it.
2.Takes a host name on the command line and prints all resulting matches for it.Takes a host name on the command line and prints all resulting matches for it.