BNY Interview Question

OOps, OOPS basics, One DSA question