Read first line of input

And initiliase 2d array