by@progrunner17
AC
`define EOF 32'hFFFF_FFFF `define STDIN 32'h8000_0000 module cat;integer c,i,d;initial begin c=$fgetc(`STDIN);while(c !=`EOF)begin d=0;i=1;while(c==48||c==49)begin d=d*2;d=d+c-48;c=$fgetc(`STDIN);end i=1;while(d>0)begin d=d-i;i=i+1;end if(d==0)begin $write("%c\n","1");end else begin $write("%c\n","0");end c=$fgetc(`STDIN);end end endmodule
01000111 11101001 11000011 00101101 11111101 10011110 01101011 11101100 01000100 01110101 00111111 01111000 01100110 00100100 00011100 01110000 00000000 00000110 00001010 01001110 10000110 01000010 01001110 10101011 10110000 00110111 01011011 11010010 10011001 10111000 10001000 00001111 00101110 00101011 00110001 01001011 00010101 01111001 00000011 01111101 10111110 11001110 10011011 00001111 01101001 10000101 00000001 11100111 10110010 10011000
0 0 0 1 1 0 0 0 0 0 0 1 0 1 1 0 1 1 1 1 0 1 1 1 0 1 1 1 1 0 1 1 0 0 0 0 1 0 1 0 1 0 0 1 1 0 1 1 0 0