you give 0indexed 8 x 8 grid board boardrc represent cell r c game board on board free cell represent white cell represent W black cell represent BEach game consist choose free cell change color play white black however legal change cell endpoint good line horizontal vertical diagonalA good line line cell include endpoint endpoint line color remain cell middle opposite color cell line free you find example good line figure belowGiven integer rMove cMove character color represent color play white black return true change cell rmove cMove color color legal false legal Example 1input board BWWWWBBWWWBBBW rMove 4 cmove 3 color boutput trueexplanation W B represent color blue white black respectively cell rMove cMove mark XThe good line choose cell endpoint annotate red rectanglesExample 2input board bwwwbbwwb rMove 4 cmove 4 color WOutput falseexplanation while good line choose cell middle cell good line choose cell endpoint Constraintsboardlength boardrlength 80 rMove cmove 8boardrmovecmove color b w