我如何在python中有一个函数,如果一个主机名解析则返回1,如果一个主机名没有则返回0.
我找不到任何有用的东西,任何想法?
谢谢,
python hostname
hostname ×1
python ×1