Sample code for Linked List Implementation and Different Algorithm