mirror of
https://github.com/TheAlgorithms/Python.git
synced 2024-11-23 21:11:08 +00:00
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
This commit is contained in:
parent
ba356ca4b4
commit
0f3c63319d
|
@ -51,7 +51,7 @@ def is_ip_v4_address_valid(ip: str) -> bool:
|
|||
False
|
||||
"""
|
||||
|
||||
parts = ip.split('.')
|
||||
parts = ip.split(".")
|
||||
|
||||
if len(parts) != 4:
|
||||
return False
|
||||
|
@ -64,7 +64,7 @@ def is_ip_v4_address_valid(ip: str) -> bool:
|
|||
if not part[i].isdigit():
|
||||
return False
|
||||
|
||||
if part[0] == '0' and len(part) > 1:
|
||||
if part[0] == "0" and len(part) > 1:
|
||||
return False
|
||||
|
||||
if not (0 <= int(part) <= 255):
|
||||
|
|
Loading…
Reference in New Issue
Block a user