Submission #732973

# Submission time Handle Problem Language Result Execution time Memory
732973 2023-04-29T22:52:25 Z rahulverma Prosjecni (COCI16_prosjecni) Java 11
24 / 120
144 ms 10988 KB
import java.io.*;
import java.util.*;

public class prosjecni {

	public static void main(String[] args) {
		Scanner s = new Scanner(System.in);
		int n = s.nextInt();
		if(n % 2 == 0) {
			System.out.println(-1);
			return;
		}
		
		int c = 1;
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < n; j++) {
				System.out.print(c + " ");
				c++;
			}
			System.out.println();
		}
		
	}

}
# Verdict Execution time Memory Grader output
1 Incorrect 98 ms 10260 KB Integer -1 violates the range [0, 1000000000]
2 Correct 134 ms 10988 KB Output is correct
3 Incorrect 105 ms 10248 KB Integer -1 violates the range [0, 1000000000]
4 Correct 144 ms 10888 KB Output is correct
5 Incorrect 102 ms 10136 KB Integer -1 violates the range [0, 1000000000]
6 Incorrect 113 ms 10100 KB Integer -1 violates the range [0, 1000000000]
7 Incorrect 97 ms 10176 KB Integer -1 violates the range [0, 1000000000]
8 Incorrect 102 ms 10280 KB Integer -1 violates the range [0, 1000000000]
9 Incorrect 113 ms 10080 KB Integer -1 violates the range [0, 1000000000]
10 Incorrect 110 ms 10080 KB Integer -1 violates the range [0, 1000000000]