Bjak Interview Question

String problem and was open internet