Back to Browse

LeetCode. 25. Reverse Nodes in k-Group. Coding in Swift.

5 views
Dec 4, 2025
16:32

Given the head of a linked list, reverse the nodes of the list k at a time, and return the 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. You may not alter the values in the list's nodes, only nodes themselves may be changed. 00:00 Intro to the task 01:07 Solving the problem 15:22 Checking and submitting the solution

Download

0 formats

No download links available.

LeetCode. 25. Reverse Nodes in k-Group. Coding in Swift. | NatokHD