Motorola Solutions interview question

A typical string arrangement questions.