implemented a single linked list as template. One error occurs