still refactoring the code

may try array lists or queues soon.