In this video, I have explained how to reverse nodes of a linked list in k-Group.
Given a linked list, reverse the nodes of a linked list k at a time and return its modified list.
k is a positive integer and is less than or equal to the length of the linked list. If the number of nodes is not a multiple of k then left-out nodes, in the end, should remain as it is.
This question is also known as following:
Reverse a Linked List in groups of given size
Reverse every group of `k` nodes in a linked list
Source code: https://github.com/fit-coder/fitcoder...
00:00 Introduction
00:09 Problem Explanation
01:40 Solution
10:07 Implementation
Reverse a Linked List: • Reverse A Linked List | 3 Methods
Reverse Sublist of a Linked List: • Reverse Sublist of Linked List | Reverse L...
Reverse Nodes in k-Group: • Reverse Nodes in K-Group | Reverse Linked ...
-------------------------------------------------------------
I live in New Delhi and love explaining programming concepts. I have done M.Tech(BITS Pilani) + B.Tech(PEC, Chandigarh) in Computer Science and am currently working as a software engineer in a MNC.
If you like my content, please like, share my videos and subscribe to the channel.
-------------------------------------------------------------
For Linked List tutorials, please refer to the below playlist:
• Linked List
For Binary tree tutorials, please refer to the below playlist:
• Tree Data Structures
For Binary search tree tutorials, please refer to the below playlist:
• Binary Search Tree
For in-depth Graph theory and implementation details, please refer to the below playlist:
• Graph Algorithms
#DataStructure,#LinkedList,#FitCoder,#Algorithm,#competitiveprogramming,#faang,#codinginterview