Result

AC

Code [DL]

module c;integer c,d,s;initial begin s=1<<31;c=$fgetc(s);while(!(&c))begin d=0;while(c!=10)begin d=d*2;d=d+c-48;c=$fgetc(s);end c=1;while(d>0)begin d=d-c;c=c+1;end if(d)begin $write("0 ");end else begin $write("1 ");end c=$fgetc(s);end end endmodule

stdin

01001111
00011101
00110110
11000010
01111000
00111010
01101001
10101001
11000011
00010000
00010100
01000111
11101001
00011100
00000011
11111101
01000010
01010101
11011001
10100100
10001000
10001000
00000110
11111110
11010010
00111101
00100101
01001110
10111110
00000000
00000001
00100100
11100111
11100101
00100111
00101101
01011011
00001111
00010101
01101001
01100001
10101011
00101010
11110111
01101000
10011001
00010110
00001010
00100000
00110111

stdout

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

stderr

strace