Given a linked list of length n and an integer k, you want to be able to partition the list into consecutive groups of exactly k nodes each (with nothing left over). Return the minimum number of nodes to remove so the remaining length is a multiple of k. Input: '[list], k'.
Input: '[list], k'.
Output: Integer — minimum nodes to remove.
Input: [1,2,3,4,5,6,7], 3
Output: 1
Explanation: 7 mod 3 = 1 node to remove.Input: [1,2,3,4], 2
Output: 0
Explanation: Already divisible.Input: [1,2,3], 3
Output: 0
Explanation: Exactly one group.0<=n<=10^51<=k<=10^5