Oracle Interview Question

Gas Sation Problem, standard queue problem.