This video contains Must Do Coding Questions for Companies like Amazon, Microsoft, Adobe, …
from geeksforgeeks platform.
website link:
https://www.geeksforgeeks.org/must-do...
Topics covered in this video series are:
1.Arrays
• 1.1 ARRAYS | Must Do Coding Questions
2.String
• 1.2 STRING | Must Do Coding Questions
3.Linked List
• 1.3 LINKED LIST | Must Do Coding Questions
4.Stack and Queue
5.Tree and BST
6.Heap
7.Recursion
8.Hashing
9.Graph
10.Greedy
11.Dynamic Programming
12.Divide and Conquer
13.Backtracking
14.Bit Magic
Linked List:
1. Finding middle element in a linked list:
Given a singly linked list of N nodes. The task is to find the middle of the linked list. For example, if given linked list is 1--2--3--4--5 then the output should be 3.
If there are even nodes, then there would be two middle nodes, we need to print the second middle element. For example, if given linked list is 1--2--3--4--5--6 then the output should be 4.
Example 1:
Input:
LinkedList: 1 2 3 4 5
Output: 3
Explanation:
Middle of linked list is 3.
Example 2:
Input:
LinkedList: 2 4 6 7 5 1
Output: 7
Explanation:
Middle of linked list is 7.
Code Link:
https://github.com/krishna-gavas/Comp...
Intro Music :
• Video p