Result

AC

Code [DL]

for(a=java.util.Scanner(java.lang.System.in);;)print(+!(Math.sqrt(parseInt(a.nextLine(),2)*8+1)%1))

stdin

00011100
01111000
01101001
11010010
10101011
10010111
01010111
10001000
00001010
00101011
00000110
11101111
11101000
00010001
01100001
00101101
01001110
00001010
00110111
00100100
11011010
00001100
00000001
01010101
10011100
01001011
11001100
11010000
10110010
11111010
11110001
01011011
11011000
01000001
11100111
11100100
11111101
00010101
00110101
01001000
11000010
00000011
11010111
01011011
10111110
00000000
00001000
01000010
10011001
00001111

stdout

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

stderr

org.mozilla.javascript.WrappedException: Wrapped java.util.NoSuchElementException: No line found
	at org.mozilla.javascript.Context.throwAsScriptRuntimeEx(Context.java:1893)
	at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:148)
	at org.mozilla.javascript.NativeJavaMethod.call(NativeJavaMethod.java:225)
	at org.mozilla.javascript.optimizer.OptRuntime.callProp0(OptRuntime.java:85)
	at org.mozilla.javascript.gen._volume_CODE_1._c_script_0(Unknown Source)
	at org.mozilla.javascript.gen._volume_CODE_1.call(Unknown Source)
	at org.mozilla.javascript.ContextFactory.doTopCall(ContextFactory.java:393)
	at org.mozilla.javascript.ScriptRuntime.doTopCall(ScriptRuntime.java:3282)
	at org.mozilla.javascript.gen._volume_CODE_1.call(Unknown Source)
	at org.mozilla.javascript.gen._volume_CODE_1.exec(Unknown Source)
	at org.mozilla.javascript.tools.shell.Main.processFileSecure(Main.java:601)
	at org.mozilla.javascript.tools.shell.Main.processFile(Main.java:560)
	at org.mozilla.javascript.tools.shell.Main.processSource(Main.java:531)
	at org.mozilla.javascript.tools.shell.Main.processFiles(Main.java:179)
	at org.mozilla.javascript.tools.shell.Main$IProxy.run(Main.java:100)
	at org.mozilla.javascript.Context.call(Context.java:501)
	at org.mozilla.javascript.ContextFactory.call(ContextFactory.java:503)
	at org.mozilla.javascript.tools.shell.Main.exec(Main.java:161)
	at org.mozilla.javascript.tools.shell.Main.main(Main.java:136)
Caused by: java.util.NoSuchElementException: No line found
	at java.util.Scanner.nextLine(Scanner.java:1540)
	at sun.reflect.GeneratedMethodAccessor1.invoke(Unknown Source)
	at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
	at java.lang.reflect.Method.invoke(Method.java:498)
	at org.mozilla.javascript.MemberBox.invoke(MemberBox.java:126)
	... 17 more

strace