제출 #94144

#제출 시각아이디문제언어결과실행 시간메모리
94144ekremProsjecni (COCI16_prosjecni)C++98
24 / 120
2 ms380 KiB
#include <bits/stdc++.h>
#define st first
#define nd second
#define mp make_pair
#define pb push_back
#define N 1000005
using namespace std;

int n;

int main() {
	// freopen("in.txt", "r", stdin);
	// freopen("out.txt", "w", stdout);
	scanf("%d",&n);
	if(n % 2 == 0){
		puts("-1");
		return 0;
	}
	for(int i = 1; i <= n; i++,puts(""))
		for(int j = 1; j <= n; j++)
			printf("%d ", (i - 1)*n + j);
	return 0;
}

컴파일 시 표준 에러 (stderr) 메시지

prosjecni.cpp: In function 'int main()':
prosjecni.cpp:14:7: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%d",&n);
  ~~~~~^~~~~~~~~
#Verdict Execution timeMemoryGrader output
Fetching results...