Reverse the list taking k elements at a time

segmentation fault occur in my code

Hey
Can you post your code?

can u plzz check my code and clear my doubt