Accretive Technology Group services may need to insert an item at a specific position in an ordered in-memory list. Implement insertion into a singly linked list without converting it to a list.
Each node is represented as a two-element list: [value, next_node]. The next_node is another node or None. Given the head node, a value, and a valid zero-based index, insert a new node at that index and return the resulting head.
Implement insert_at_index(head, value, index).
head, a node represented as [value, next_node], or None; value, an integer; and index, a valid zero-based insertion position.def insert_at_index(head, value, index):