Result

WA

Code [DL]

s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}

stdin

11101011
00000001
00000110
01100111
10110001
10100111
00000000
01000101
00100010
01000010
11110110
11101101
01111011
11111101
01100000
10001000
01101100
00011110
11011101
00010101
00101101
00011100
10101110
10011001
11010010
10101001
00101110
11110010
10100101
01101001
11100111
00110111
00000011
00011010
00010010
10111110
11111101
01000011
11000010
01111000
01000110
11000101
01011011
00001111
11101001
01001110
00001010
00100100
10101011
00000001

stdout

0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0
1
0
0
0
0
0
0
1
0
0
0
0
0
0
0
0
0
0
0
0
0
0
0

stderr

/tmp/code.c:1:1: warning: data definition has no type or storage class
 s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}
 ^
/tmp/code.c:1:1: warning: type defaults to ‘int’ in declaration of ‘s’ [-Wimplicit-int]
/tmp/code.c:1:6: warning: return type defaults to ‘int’ [-Wimplicit-int]
 s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}
      ^
/tmp/code.c: In function ‘main’:
/tmp/code.c:1:6: warning: type of ‘j’ defaults to ‘int’ [-Wimplicit-int]
/tmp/code.c:1:6: warning: type of ‘a’ defaults to ‘int’ [-Wimplicit-int]
/tmp/code.c:1:6: warning: type of ‘t’ defaults to ‘int’ [-Wimplicit-int]
/tmp/code.c:1:23: warning: implicit declaration of function ‘gets’ [-Wimplicit-function-declaration]
 s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}
                       ^
/tmp/code.c:1:31: warning: implicit declaration of function ‘puts’ [-Wimplicit-function-declaration]
 s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}
                               ^
/tmp/code.c:1:48: warning: implicit declaration of function ‘strtol’ [-Wimplicit-function-declaration]
 s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}
                                                ^
/tmp/code.c:1:78: warning: operation on ‘j’ may be undefined [-Wsequence-point]
 s[9];main(j,a,t){for(;gets(s);puts(&a))for(j=t=strtol(s,0,2),a=48;j+2;)a+=j*(--j)==t*2;}
                                                                              ^
/tmp/ccFBGPPP.o: In function `main':
code.c:(.text.startup+0x10): warning: the `gets' function is dangerous and should not be used.

strace