矩阵系列
矩阵系列
爱敲代码的Harrison
种一棵树最好的时间是十年前,其次是现在。
展开
-
PrintStar
题目package com.harrison.class29;/** * @author Harrison * @create 2022-04-09-21:39 * @motto 众里寻他千百度,蓦然回首,那人却在灯火阑珊处。 */public class Code04_PrintStar { public static void printStar(int N) { int leftUp = 0; int rightDown = N - 1;原创 2022-04-09 21:41:07 · 359 阅读 · 0 评论 -
之字形打印矩阵——ZigZagPrintMatrix
package com.harrison.class29;/** * @author Harrison * @create 2022-04-09-21:27 * @motto 众里寻他千百度,蓦然回首,那人却在灯火阑珊处。 */public class Code03_ZigZagPrintMatrix { public static void printMatrixZigZag(int[][] matrix) { int tR = 0; int tC =原创 2022-04-09 21:39:26 · 371 阅读 · 0 评论 -
打印螺旋矩阵
package com.harrison.class29;/** * @author Harrison * @create 2022-04-09-21:02 * @motto 众里寻他千百度,蓦然回首,那人却在灯火阑珊处。 */public class Code02_PrintMatrixSpiralOrder { public static void spiralOrderPrint(int[][] matrix) { int tR = 0; int原创 2022-04-09 21:26:43 · 260 阅读 · 0 评论 -
矩阵旋转,
题目package com.harrison.class28;/** * @author Harrison * @create 2022-04-09-16:22 * @motto 众里寻他千百度,蓦然回首,那人却在灯火阑珊处。 */public class Code05_RotateMatrix { public static void rotate(int[][] m){ int a=0; int b=0; int c=m.leng原创 2022-04-09 16:33:19 · 326 阅读 · 0 评论