Innovacer | R-1

Posted
15 Jan 2026
297 reads

Summary

I encountered a linked list problem titled 'Reverse in Groups of Increasing Size' during my interview at Innovacer, but I was unable to complete the solution.

How it went

Problem: Reverse in Groups of Increasing Size You are given a singly linked list. Reverse the nodes of the list in groups of increasing size: The 1st group has 1 node, The 2nd group has 2 nodes, The 3rd group has 3 nodes, and so on. If the remaining nodes are fewer than the required group size, leave them as they are.

Example 1 Input: 1 → 20 → 3 → 5 → 50 → 2 → 100 → 15 → 9
Process: Group 1 (size=1): [1] → stays as [1]
Group 2 (size=2): [20,3] → reversed to [3, 20]
Group 3 (size=3): [5,50,2] → reversed to [2, 50, 5]
Group 4 (size=4): [100,15,9] → only 3 nodes < 4 → leave as is
Output: 1->3->20->2->50->5->100->15->9

I wasn't able to reach till the end.
Similar too : https://leetcode.com/problems/reverse-nodes-in-k-group/submissions/1884845981/

Questions asked (1)

  1. 01

    Reverse Linked List in Increasing Size Groups

    Data Structures & Algorithms · Hard

    You are given a singly linked list. Reverse the nodes of the list in groups of increasing size: The 1st group has 1 node, The 2nd group has 2 nodes, The 3rd group has 3 nodes, and so on. If the remaining nodes are fewer than the required group size, leave them as they are.

    Example 1 Input: 1 → 20 → 3 → 5 → 50 → 2 → 100 → 15 → 9
    Process: Group 1 (size=1): [1] → stays as [1]
    Group 2 (size=2): [20,3] → reversed to [3, 20]
    Group 3 (size=3): [5,50,2] → reversed to [2, 50, 5]
    Group 4 (size=4): [100,15,9] → only 3 nodes < 4 → leave as is
    Output: 1->3->20->2->50->5->100->15->9

    Open the problem

Know someone preparing? Send it to them:WhatsAppLinkedInX

Interviewed at Innovacer recently?

Write up your rounds while you still remember the questions. It helps the next person more than you would think.

Share your experience
Discussion 0

Questions for the author, or how your own interview compared.

Join the discussion

Sign in with Google to comment or ask the author a question.

No comments yet

Be the first to share your thoughts and start the discussion!