Find max number of squares (S) of side 2 units that can fit in an Isosceles triangle with a right angle and its shortest side equal to "B" units. Note: The squares don't have to fit completely inside the Triangle.
Input:B = 1Output:0Explanation:We can't fit any squares.
Input:B = 10Output:10Explanation:We can fit 10 squares of 2 unit sides
in an Isosceles Right Traingle with
the shortest side being 10 unit length.
You don't need to read input or print anything. Your task is to complete the function maxSquares() which takes an Integer B as input and returns the answer.
Expected Time Complexity: O(1) Expected Auxiliary Space: O(1)