Stack Abstract Data Type using Ada
The stack Abstract Data Type is one of the simplest data types to create and understand. There are fundamentally two kinds of stack types. · bounded stacks which have a pre-determined capacity · unbounded stacks which can grow to the limits of computer memory. Every stack implementation has some common subprograms. · Is_Empty – This function returns true if the stack is empty and false if it is not empty · Size – A function returning number of elements currently contained by the stack · Top – A function returning the top element of a stack that is not empty · Push – Push a data element onto the stack · Pop – A procedure that pops the ...