• Courses
  • Tutorials
  • Jobs
  • Practice
  • Contests
September 13, 2023 |280 Views
SDE Sheet - Add two numbers represented by Linked lists
  Share   Like
Description
Discussion

This video is part of the Linked List section in the GFG SDE Sheet.

In this video, we are given two decimal numbers represented by two linked lists of size N and M respectively. The task is to return a linked list that represents the sum of these two numbers.

For example, the number 190 will be represented by the linked list, 1->9->0->null, similarly 25 by 2->5->null. Sum of these two numbers is 190 + 25 = 215, which will be represented by 2->1->5->null. We are required to return the head of the linked list 2->1->5->null.

Try it out before watching the implementation of the problem in the video. We recommend watching the video, even if you can solve the problem. You may discover something new. All the best!!!

Do check out:-

Article: https://www.geeksforgeeks.org/add-two-numbers-represented-by-linked-list/
Problem: https://practice.geeksforgeeks.org/problems/add-two-numbers-represented-by-linked-lists/1
SDE Sheet: https://www.geeksforgeeks.org/sde-sheet-a-complete-guide-for-sde-preparation/

Read More