Add Two Numbers II
Updated
Problem statement
Two nonnegative integers are stored in forward digit order in linked lists l1 and l2. Return their sum as a forward-order digit list.
Do not reverse or mutate the input lists.
Function
addTwoNumbersForward(l1: ListNode, l2: ListNode) → ListNodeExamples
Example 1
l1 = [7,2,4,3]l2 = [5,6,4]return = [7,8,0,7]7243 + 564 = 7807.
Example 2
l1 = [9,9]l2 = [1]return = [1,0,0]The final carry becomes the new head.
Constraints
- Each list has between
1and100nodes. - Every node value is a decimal digit.
More Bloomberg LP Onsite Interview questions
- N-ary Index-Path Encoder and DecoderPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
- Top K Frequent WordsONSITE INTERVIEW · Seen Nov 2026
- Trapping Rain WaterPHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
- Word SearchOA · PHONE SCREEN · ONSITE INTERVIEW · Seen Nov 2026
- Design Browser HistoryPHONE SCREEN · ONSITE INTERVIEW · Seen Oct 2026
- Mutable Stock Price Top KPHONE SCREEN · ONSITE INTERVIEW · Seen Oct 2026
- Decode StringPHONE SCREEN · ONSITE INTERVIEW · Seen Oct 2026
- Minimum Replacements to Make Two Strings AnagramsPHONE SCREEN · ONSITE INTERVIEW · Seen Sep 2026
- Currency Conversion RatePHONE SCREEN · ONSITE INTERVIEW · Seen Sep 2026
- Running Stream AggregatesONSITE INTERVIEW · Seen Sep 2026
Similar questions at other companies
- Subtract Forward-Order Linked-List NumbersMicrosoft · ONSITE INTERVIEWMicrosoft interview questions
- Add Forward Linked-List Numbers Using RecursionPeopleStrong · PHONE SCREENPeopleStrong interview questions
- Calculate a Token-List ExpressionCollege Vine · ONSITE INTERVIEW
- Basic Calculator IISnap Inc. · PHONE SCREENSnap Inc. interview questions
- Evaluate a Prefix ExpressionGoogle · ONSITE INTERVIEWGoogle interview questions
- Turn a BST Into a Sorted Doubly Linked ListAdobe · PHONE SCREENAdobe interview questions
- Min StackCapital One · PHONE SCREEN · ONSITE INTERVIEWCapital One interview questions
- Add Two Numbers Stored in Reversed ListsExpedia · ONSITE INTERVIEWExpedia interview questions
- Evaluate Reverse Polish NotationCoalition · PHONE SCREEN
- Add Numbers Stored in Four-Digit ChunksZipRecruiter · ONSITE INTERVIEWZipRecruiter interview questions
Interview reports that mention this question
Bloomberg LP interview experiences
- Bloomberg AI-Assisted Coding Round, All Levels: 14 Experiences
- Bloomberg SWE Intern Interview Questions: 68 Questions
- Bloomberg Interview Questions, Level Not Reported: 65 Questions
- Bloomberg Experienced SWE Interviews: 167 Questions (Part 1 of 2)
- Bloomberg New Grad Coding Questions: 121 Questions (Part 2 of 2)