想要将几个文件的第一列转换为行,而字段宽度应根据最长的单词并填充空格并以逗号结尾。有人可以帮忙吗?
INPUT1
HELLO
WORLD
SOUTH is
WARM
NORTH is
COLD
输入2
HELLO
WORLD
SOUTH
WARM
NORTH
COLD
输出
HELLO ,WORLD ,SOUTH is ,WARM ,NORTH is ,COLD ,
HELLO ,WORLD ,SOUTH ,WARM ,NORTH ,COLD ,