adding linkedlist and queue ds problems