# # 验证IP地址 # @param IP string字符串 一个IP地址字符串 # @return string字符串 # class Solution: def solve(self , IP ): # write code here if '.' in IP: for ip in IP.split('.'): if ip.isdigit() is False or ip == '' or ip[0] == '0' or (not 0 <= int(ip) <= 255): ...