1. 首页
  2. 数据库
  3. 其它
  4. 《剑指Offer》刷题笔记——面试题29. 顺时针打印矩阵

《剑指Offer》刷题笔记——面试题29. 顺时针打印矩阵

上传者: 2020-12-22 13:31:00上传 PDF文件 52.65KB 热度 14次
难度:简单 一、题目描述: 二、解题分析: 1、leetcode解析 2、代码实现 class Solution: def spiralOrder(self, matrix: List[List[int]]) -> List[int]: if not matrix:return [] m,n = len(matrix),len(matrix[0]) x = y = di = 0 dx = [0,1,0,-1] dy = [1,0,-1,0] res = [] visite
下载地址
用户评论