练习第二天 Z4 二维数组中的查找 我的暴力解法,时间空间复杂度都比较小,但还可以直接进行优化 class Solution: def Find(self , target: int, array: List[List[int]]) -> bool: # write code here # 暴力解法,在这肯定会超出时间限制 for i in array: if target in i: return True # 其他的情况 return False 别人的时间复杂度较小的解法,核心思路使用查找,两个游标进行有序数字的划分处理,时间更少一些,且不需要开辟额外的相关空间 #使用查找的思路...