Micro1 interview question

About string reorganizing using two priority queue