style:fmt

This commit is contained in:
dichgrem
2025-11-15 13:30:17 +08:00
parent c20e8949a5
commit 41e6b71bd7
33 changed files with 549 additions and 543 deletions

View File

@@ -3,21 +3,21 @@ package com.study.demo;
import java.util.Scanner;
public class test3_4 {
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int n = scanner.nextInt();
int m = scanner.nextInt();
int[][] image = new int[n][m];
for (int i = 0; i < n; i++) {
for (int j = 0; j < m; j++) {
image[i][j] = scanner.nextInt();
}
}
for (int j = 0; j < m; j++) {
for (int i = n - 1; i >= 0; i--) {
System.out.print(image[i][j] + (i == 0 ? "" : " "));
}
System.out.println();
}
public static void main(String[] args) {
Scanner scanner = new Scanner(System.in);
int n = scanner.nextInt();
int m = scanner.nextInt();
int[][] image = new int[n][m];
for (int i = 0; i < n; i++) {
for (int j = 0; j < m; j++) {
image[i][j] = scanner.nextInt();
}
}
for (int j = 0; j < m; j++) {
for (int i = n - 1; i >= 0; i--) {
System.out.print(image[i][j] + (i == 0 ? "" : " "));
}
System.out.println();
}
}
}