mirror of
https://github.com/SunnyQjm/algorithm-review.git
synced 2026-06-03 08:16:43 +08:00
Update check-out-of-order-string.py
This commit is contained in:
@@ -25,7 +25,7 @@ class Solution:
|
||||
思路:
|
||||
1. 将两个字符串转为list;
|
||||
2. 堆两个list进行排序;
|
||||
3. 然后注意比较对应位置的字符是否相等即可
|
||||
3. 然后逐一比较对应位置的字符是否相等即可
|
||||
"""
|
||||
# 特判字符串长度不相同的情况
|
||||
# 其实这个不是必须的,只是在输入有可能长度不一的情况下,用这个可能可以提高一点性能
|
||||
|
||||
Reference in New Issue
Block a user