Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit fd7fbfd

Browse files
Update README.md
1 parent 6721b7f commit fd7fbfd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

‎README.md‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ class Solution:
115115
def myAtoi(self, s: str) -> int:
116116
return max(min(int(*re.findall('^[\+\-]?\d+', s.lstrip())), 2**31 - 1), -2**31)
117117
```
118-
- 使用正则表达式 `^:匹配字符串开头,[\+\-]:代表一个+字符或-字符,?:前面一个字符可有可无,\d:一个数字,+:前面一个字符的一个或多个,\D:一个非数字字符,*:前面一个字符的0个或多个`
118+
- 使用正则表达式 `^:匹配字符串开头,[\+\-]:代表一个+字符或-字符,?:前面一个字符可有可无,\d:一个数字,+:前面一个字符的一个或多个,\D:一个非数字字符`
119119
- `max(min(数字, 2**31 - 1), -2**31)` 用来防止结果越界
120120
## [9. Palindrome Number 1行](https://leetcode.com/problems/palindrome-number/)
121121

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /