Spiral Matrix II
时间:2014-03-08 16:06:26
收藏:0
阅读:481
Given an integer n, generate a square matrix filled with elements from 1 to n2 in spiral order.
For example,
Given n = 3
,
[ [ 1, 2, 3 ], [ 8, 9, 4 ], [ 7, 6, 5 ] ]
Spiral Matrix II,布布扣,bubuko.com
原文:http://blog.csdn.net/icomputational/article/details/20771135
评论(0)