mirror of
https://github.com/bolucat/Archive.git
synced 2025-12-24 13:28:37 +08:00
23 lines
346 B
Python
23 lines
346 B
Python
#!/usr/bin/python
|
|
# -*- encoding: utf8 -*-
|
|
|
|
import itertools
|
|
import math
|
|
import sys
|
|
|
|
import IPy
|
|
|
|
|
|
def main():
|
|
china_list_set = IPy.IPSet()
|
|
for line in sys.stdin:
|
|
china_list_set.add(IPy.IP(line))
|
|
|
|
# 输出结果
|
|
for ip in china_list_set:
|
|
print '<item>' + str(ip) + '</item>'
|
|
|
|
|
|
if __name__ == "__main__":
|
|
main()
|