摘要: 我太难了,俩小时。。。。。。 class Solution(object): def isNumber(self, s): """ :type s: str :rtype: bool """ s=s.strip() for i in range(len(s)): if s[i] not in 'e0 阅读全文
posted @ 2019-10-11 20:12 欣姐姐 阅读(194) 评论(0) 推荐(0) 编辑
摘要: 看着挺简单,结果不断出错不断修改,就很容易绕晕了,用了一个小时四十分钟左右才完成。。。好慢哦: class Solution(object): def myAtoi(self, str): """ :type str: str :rtype: int """ a=str.lstrip() if le 阅读全文
posted @ 2019-10-11 17:23 欣姐姐 阅读(268) 评论(0) 推荐(0) 编辑
摘要: class Solution(object): def convert(self, s, numRows): """ :type s: str :type numRows: int :rtype: str """ if numRows==1: return s if len(s)<2: return 阅读全文
posted @ 2019-10-11 15:58 欣姐姐 阅读(142) 评论(0) 推荐(0) 编辑
摘要: 执行用时 :2192 ms, 在所有 Python 提交中击败了50.51%的用户 内存消耗 :115.1 MB, 在所有 Python 提交中击败了5.06%的用户 虽然好不容易用俩小时左右做出来了,但是感觉还是有地方很啰嗦。 执行用时为 20 ms 的范例 class Solution(obje 阅读全文
posted @ 2019-10-11 13:59 欣姐姐 阅读(157) 评论(0) 推荐(0) 编辑