Merge pull request #62392 from timothyqiu/valid-integer
[3.x] Fix code example of `String.is_valid_integer()`
This commit is contained in:
commit
b9057a71ae
1 changed files with 5 additions and 5 deletions
|
@ -488,11 +488,11 @@
|
|||
<description>
|
||||
Returns [code]true[/code] if this string contains a valid integer.
|
||||
[codeblock]
|
||||
print("7".is_valid_int()) # Prints "True"
|
||||
print("14.6".is_valid_int()) # Prints "False"
|
||||
print("L".is_valid_int()) # Prints "False"
|
||||
print("+3".is_valid_int()) # Prints "True"
|
||||
print("-12".is_valid_int()) # Prints "True"
|
||||
print("7".is_valid_integer()) # Prints "True"
|
||||
print("14.6".is_valid_integer()) # Prints "False"
|
||||
print("L".is_valid_integer()) # Prints "False"
|
||||
print("+3".is_valid_integer()) # Prints "True"
|
||||
print("-12".is_valid_integer()) # Prints "True"
|
||||
[/codeblock]
|
||||
</description>
|
||||
</method>
|
||||
|
|
Loading…
Reference in a new issue