Implementation of stack, queue data structure in objective C