You are given two non-empty linked lists representing two non-negative integers, with digits stored in reverse order. Add the two numbers and return the sum as a linked list, also in reverse order.
Input: l1 = [2,4,3], l2 = [5,6,4]
Output: [7,0,8]
Explanation: 342 + 465 = 807.
Topics: linked-list, recursion
Asked by: Amazon, Microsoft, Meta, Adobe
Time complexity: O(max(m, n)). Space complexity: O(max(m, n)).