Medium

Alice and Bob Playing Flower GamePython

Full explanation · Time O(1) · Space O(1)

# Time:  O(1)
# Space: O(1)

# combinatorics
class Solution(object):
    def flowerGame(self, n, m):
        """
        :type n: int
        :type m: int
        :rtype: int
        """
        return (n*m)//2