Input has an unknown amount of lines of Strings of length 20 each. I am using BufferedReader
to take inputs from the console. After the last input it's just waiting for the input. How can I terminate the process?
Example Input:
10100101111011111111
00000000000000000000
01011101110110101111
Above 3 lines are given as input. But its not given there are going to be 3 line of input. That is unknown and my programme is just waiting for the next input after the last line, when it should be terminating.
There is no terminator specified in the problem.