Easiest  Solution in C++ and Java
\n\n# Approach\n Describe your approach to solving the problem. \n1. Calculate sum of arrivalTime and delayedTime in an integer named c.\n2. If c is less than o
\n\n# Approach\n<!-- Describe your approach to solving the problem. -->\n1. Calculate sum of arrivalTime and delayedTime in an integer named **c**.\n2. If **c is less than or equal to 23** return c as it is.\n3. If **(c==24)** return 0.\n4. Else return **(c-24)**.\n\n![Screenshot (26).png](https://assets.leetcode.com/users/images/2fca416a-143a-4a75-a806-d0922906a79f_1703249147.183868.png)\n\n\n# Complexity\n- Time complexity:0 ms\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:6.25 MB\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n# C++\n```\nclass Solution {\npublic:\n    int findDelayedArrivalTime(int arrivalTime, int delayedTime) {\n        int c=arrivalTime+delayedTime;\n        if((c)<=23)\n        return c;\n        else if(c==24)\n        return 0;\n        else\n        return c-24;\n\n    }\n};\n```\n# Java\n```\nclass Solution {\n    public int findDelayedArrivalTime(int arrivalTime, int delayedTime) {\n        int c = arrivalTime + delayedTime;\n        if (c <= 23)\n            return c;\n        else if (c == 24)\n            return 0;\n        else\n            return c - 24;\n    }\n}\n```
['Math', 'C++', 'Java']