我的教授要求按列对二维字符数组进行排序,因此他想要排序的附加数组是
unsorted sorted last column
Lcekoeddhoffbmg Balgfcaelhfkgeb
Lkcmggjcdhhglif Kmlhmhcddfoeilc
Cgldjhcekjigcdd Cgldjhcekjigcdd
Cgldjhcekjigcdn Lkcmggjcdhhglif
Bffmdbkcenlafjk Lcekoeddhoffbmg
Fggdijijegfblln Jjlncnimjldfedj
Jjlncnimjldfedj Bffmdbkcenlafjk
Amliglfohajcdmm Amliglfohajcdmm
Balgfcaelhfkgeb Fggdijijegfblln
Kmlhmhcddfoeilc Cgldjhcekjigcdn
但问题是他希望整行都是相同的字符,所以如果我们对最后一列进行排序,我们只需相应地向上或向下移动行。我不知道如何开始这项工作,任何帮助将不胜感激