发布时间:2019-08-26 07:20:06编辑:auto阅读(2115)
>>> import socket
>>> name = socket.gethostname()
>>> print name
***-***-***-**
>>> ip_addr = socket.gethostbyname(name)
>>> print ip_addr
10.***.*.*
上一篇: 【python】 倒序输出字符串
下一篇: Python除法运算和幂运算代码实例
48943
48072
38817
35939
30356
27142
26140
20976
20801
19151
689°
760°
738°
741°
719°
675°
781°
858°
997°
1241°