Infosys interview question

OOP stack queue database java