Fidelity Investments Interview Question

Some string related coding task