1 Liner Simple Solution, Using Simple Maths, [C++]
Implementation\n\nUsing Simple Maths\nTime Complexity : O(1)\nSpace Complexity : O(1)\n\n\nclass Solution {\npublic:\n    bool isRectangleOverlap(vector<int>& r
Implementation\n\n**Using Simple Maths\nTime Complexity : O(1)\nSpace Complexity : O(1)**\n\n```\nclass Solution {\npublic:\n    bool isRectangleOverlap(vector<int>& rec1, vector<int>& rec2) {\n        return rec1[0] < rec2[2] && rec1[1] < rec2[3] && rec2[0] < rec1[2] && rec2[1] < rec1[3];\n    }\n};\n```\nIf you find any issue in understanding the solution then comment below, will try to help you.\nIf you found my solution useful.\nSo **please do upvote and encourage me** to document all leetcode problems\uD83D\uDE03\nHappy Coding :)
['Math', 'C']