add exercise: functional linked lists in javascript