commit a linked list code