摘要: Problem Statement Given a positive integer n, generate a square matrix filled with elements from 1 to n2 in spiral order. Example: Input: 3 Output: [ 阅读全文
posted @ 2019-12-10 15:10 包子模拟面试 阅读(280) 评论(0) 推荐(0) 编辑
摘要: Problem Statement Given a matrix of m x n elements (m rows, n columns), return all elements of the matrix in spiral order. Example 1: Input: [ [ 1, 2, 阅读全文
posted @ 2019-12-10 12:34 包子模拟面试 阅读(241) 评论(0) 推荐(0) 编辑