This commit is contained in:
youngyangyang04
2022-02-28 20:52:01 +08:00
parent 266702c291
commit 37e7d73ec2
42 changed files with 64 additions and 60 deletions

View File

@@ -159,7 +159,7 @@ class Solution {
```
Python
```python3
```python
# 方法一,仅使用栈,更省空间
class Solution:
def isValid(self, s: str) -> bool:
@@ -180,7 +180,7 @@ class Solution:
return True if not stack else False
```
```python3
```python
# 方法二,使用字典
class Solution:
def isValid(self, s: str) -> bool: