#Initialize a complex number cn = complex(,) print("Complex Number: ",cn) print("Complex Number - Real part: ",cn.real) print("Complex Number - Imaginary part: ",cn.imag)
python 获取 mac 地址 的例子,有需要的朋友可以参考下. #!/bin/python import os import re def GetMac(): if os.name == 'nt': try: ret = '' CmdLine = 'ipconfig /all' r = os.popen(CmdLine).read() if r: