View Code of Problem 109

#include <stdio.h>
int main()
{
	int n,a,b;
  	sacnf("%d",&n)
          while(scanf("%d %d",a,b!)=EOF)
            printf("%d",a+b);




}
/*
Main.c: In function 'main':
Main.c:5:4: warning: implicit declaration of function 'sacnf' [-Wimplicit-function-declaration]
    sacnf("%d",&n)
    ^
Main.c:6:11: error: expected ';' before 'while'
           while(scanf("%d %d",a,b!)=EOF)
           ^
Main.c:4:10: warning: unused variable 'b' [-Wunused-variable]
  int n,a,b;
          ^
Main.c:4:8: warning: unused variable 'a' [-Wunused-variable]
  int n,a,b;
        ^
*/

Double click to view unformatted code.


Back to problem 109