validating the input with row,column and section