Submission #21145

# Submission time Handle Problem Language Result Execution time Memory
21145 2017-04-06T08:01:15 Z jayceking scanf 함수 1 (BSC_0_3) C++14
0 / 100
0 ms 1116 KB
#include<cstdio>

int main() {
	int a;
	scanf("%d", &a);
	printf("%d", &a);
}

Compilation message

scanf1.cpp: In function 'int main()':
scanf1.cpp:6:17: warning: format '%d' expects argument of type 'int', but argument 2 has type 'int*' [-Wformat=]
  printf("%d", &a);
                 ^
scanf1.cpp:5:17: warning: ignoring return value of 'int scanf(const char*, ...)', declared with attribute warn_unused_result [-Wunused-result]
  scanf("%d", &a);
                 ^

# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 1116 KB Output isn't correct
2 Halted 0 ms 0 KB -