Question 9
You have been given a R × C chessboard, with a list of squares cut out. This problem will involve placing rooks on a chessboard, so that they cannot attack each other. For a rook to attack a target piece, it must share the same row or column as the target.
Find the maximum number of rooks that can be placed on the chessboard, such that no pair of rooks can attack each other.
Rooks cannot be placed on cut out squares. The cut out squares do not affect where the rooks can attack.
Based on the above data, answer the given subquestions.
What is the answer if R = C = N and all the squares on the topmost row and rightmost column (i.e, a L-shape) are cut out?