How to find Google's IP address?

后端 未结 8 1967
悲&欢浪女
悲&欢浪女 2020-12-23 22:20

Google is blocked in some countries. However, there are many ways to access Google, like VPN, agent, and by changing the hosts file.

If I want to change the hosts f

8条回答
  •  星月不相逢
    2020-12-23 23:02

    import socket
    s = socket.socket(socket.AF_INET, socket.SOCK_STREAM)
    server = www.google.com
    port = 80
    server_ip = socket.gethostbyname(server)
    print(str(server_ip))
    

提交回复
热议问题