Submission #13465

# Submission time Handle Problem Language Result Execution time Memory
13465 2015-02-21T03:55:26 Z gs14004 scanf 함수 5 (BSC_0_7) C++14
Compilation error
0 ms 0 KB
#include <stdio.h>
  
int main(){
  int t,u;scanf("%d %d",&t,&u);printf("%g",0.5*(a+b));
}

Compilation message

scanf5.cpp: In function ‘int main()’:
scanf5.cpp:4:49: error: ‘a’ was not declared in this scope
   int t,u;scanf("%d %d",&t,&u);printf("%g",0.5*(a+b));
                                                 ^
scanf5.cpp:4:51: error: ‘b’ was not declared in this scope
   int t,u;scanf("%d %d",&t,&u);printf("%g",0.5*(a+b));
                                                   ^
scanf5.cpp:4:31: warning: ignoring return value of ‘int scanf(const char*, ...)’, declared with attribute warn_unused_result [-Wunused-result]
   int t,u;scanf("%d %d",&t,&u);printf("%g",0.5*(a+b));
                               ^