Skip to content

Commit 3d07a34

Browse files
Contributes to #9943
1 parent fcf82a1 commit 3d07a34

File tree

3 files changed

+19
-1
lines changed

3 files changed

+19
-1
lines changed

.devcontainer/devcontainer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
// Update 'VARIANT' to pick a Python version: 3, 3.11, 3.10, 3.9, 3.8
88
// Append -bullseye or -buster to pin to an OS version.
99
// Use -bullseye variants on local on arm64/Apple Silicon.
10-
"VARIANT": "3.12-bookworm",
10+
"VARIANT": "3.12-bookworm"
1111
}
1212
},
1313

.gitignore

+1
Original file line numberDiff line numberDiff line change
@@ -108,3 +108,4 @@ venv.bak/
108108
.try
109109
.vscode/
110110
.vs/
111+
.devcontainer/devcontainer.json

strings/indian_phone_validator.py

+17
Original file line numberDiff line numberDiff line change
@@ -26,4 +26,21 @@ def indian_phone_validator(phone: str) -> bool:
2626

2727

2828
if __name__ == "__main__":
29+
"""
30+
Main entry point of the script.
31+
32+
This block checks if the script is being run as the main module. If so, it calls
33+
the `indian_phone_validator` function with a sample phone number and prints the result.
34+
35+
Functions:
36+
indian_phone_validator(phone: str) -> bool:
37+
Validates if the given phone number is a valid Indian phone number.
38+
The function is expected to return `True` if the number is valid, otherwise `False`.
39+
40+
Example:
41+
$ python indian_phone_validator.py
42+
True # (if the phone number "+918827897895" is valid)
43+
44+
Note: Ensure that the `indian_phone_validator()` function is defined elsewhere in the code.
45+
"""
2946
print(indian_phone_validator("+918827897895"))

0 commit comments

Comments
 (0)