Easy to understand 99% Running time with HANDWRITTEN STEP BY STEP GUIDE detailed Explanation
Intuition\n Describe your first thoughts on how to solve this problem. \nWe need to find the number of jumbo and small burgers given the total number of tomato 
# Intuition\n<!-- Describe your first thoughts on how to solve this problem. -->\nWe need to find the number of jumbo and small burgers given the total number of tomato slices and cheese slices. Each jumbo burger requires 4 tomato slices and each small burger requires 2 tomato slices.\n\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n![1lc.jpg](https://assets.leetcode.com/users/images/3ec4ab2a-d5ca-421f-8d3a-bcf374b60a99_1718216369.1380398.jpeg)\n![2lc.jpg](https://assets.leetcode.com/users/images/a53225c1-bbe2-46dc-874e-3651d76d496c_1718216374.8787735.jpeg)\n\n# Complexity\n- Time complexity:O(1)\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:O(1)\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# Code\n```\nclass Solution(object):\n    def numOfBurgers(self, tomatoSlices, cheeseSlices):\n        """\n        :type tomatoSlices: int\n        :type cheeseSlices: int\n        :rtype: List[int]\n        """\n        # jumbo: 4 tomato 1 cheese\n        # small: 2 tomato 1 cheese\n        if (tomatoSlices % 2 != 0) or ((tomatoSlices - (2* cheeseSlices)) % 2 != 0):\n            return []\n        \n        J = (tomatoSlices - (2* cheeseSlices)) // 2\n        S = cheeseSlices - J\n        if J < 0 or S < 0:\n            return []\n        \n        return [J,S]\n        \n\n```\n\n![cute_dinosaur_cooie.jpg](https://assets.leetcode.com/users/images/aec4f9c0-8eab-44cf-99b7-3f8b62d186d2_1718216401.81718.jpeg)\n
['Python']