How to write reverse without recursion

Given a head to Linked List L, write a function to reverse the list taking k elements at a time. Assume k is a factor of the size of List.

You need not have to create a new list. Just reverse the old one using head.

@hg11110000 Take two variable prev and nxt. Do
Nxt = node-> next.
Node->next = prev.
Prev= node.
Node = nxt.

there is sublist of k elements how to do for that
code which you told is to reverse whole LL

@hg11110000 Take only those elements which you have to reverse.