发布时间:2019-08-26 07:20:06编辑:auto阅读(2149)
>>> import socket
>>> name = socket.gethostname()
>>> print name
***-***-***-**
>>> ip_addr = socket.gethostbyname(name)
>>> print ip_addr
10.***.*.*
上一篇: 【python】 倒序输出字符串
下一篇: Python除法运算和幂运算代码实例
49421
48628
39318
36397
30802
27620
26606
21433
21293
19641
294°
583°
529°
626°
1332°
705°
1383°
1622°
1279°
1262°