Oracle Interview Question

given a dsa question on 3d dp