Stack implemented using an array.