JPMorganChase Interview Question

dsa questions were on strings