Given M x N Chessboard. The task is to determine the Maximum numbers of cuts that we can make in the Chessboard such that the Chessboard is not divided into 2 parts.
Input: M = 2, N = 4 Output: Maximum cuts = 3 Input: M = 3, N = 3 Output: Maximum cuts = 4
- For M = 2, N = 2 We can only make 1 cut (mark in red). if we make 1 more cut then the chessboard will divide into 2 pieces.
- For M = 2, N = 4 We can makes 3 cuts (marks in red). if we make 1 more cut then the chessboard will divide into 2 pieces.
So, it can be observed that no. of cuts = (m-1) * (n-1).
Below is the implementation of the above approach:
Maximum cuts = 9
- Minimum cuts required to divide the Circle into equal parts
- Possible cuts of a number such that maximum parts are divisible by 3
- Check if an array of 1s and 2s can be divided into 2 parts with equal sum
- Number of ways N can be divided into four parts to construct a rectangle
- Check if any square (with one colored cell) can be divided into two equal parts
- Minimum number of cuts required to make circle segments equal sized
- Minimum number of operations on a binary string such that it gives 10^A as remainder when divided by 10^B
- Break a number such that sum of maximum divisors of all parts is minimum
- Split the number into N parts such that difference between the smallest and the largest part is minimum
- Split a number into 3 parts such that none of the parts is divisible by 3
- Find minimum number to be divided to make a number a perfect square
- Maximum number of pieces in N cuts
- Count pieces of circle after N cuts
- Check if the given chessboard is valid or not
- Count Distinct Rectangles in N*N Chessboard
If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to email@example.com. See your article appearing on the GeeksforGeeks main page and help other Geeks.
Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.