javascript-algorithms
javascript-algorithms copied to clipboard
I added size func. for some data structures
I realized that we cannot access size of some structurest directly like stack, queue. We were have to access size by other objects like linkedlist.toArray().size. That is why i added size func. inside linkedlist using toArray func and i called size func. of linkedlist inside other structures.(stack, queue, doublylindkedlist.) Now we can directly access size inside data structures like stack and queue.