发布时间:2019-08-26 07:20:06编辑:auto阅读(2145)
>>> import socket
>>> name = socket.gethostname()
>>> print name
***-***-***-**
>>> ip_addr = socket.gethostbyname(name)
>>> print ip_addr
10.***.*.*
上一篇: 【python】 倒序输出字符串
下一篇: Python除法运算和幂运算代码实例
49387
48584
39276
36361
30771
27584
26577
21397
21260
19606
250°
488°
478°
566°
931°
639°
1320°
1573°
1243°
1226°