Chinaunix

标题: 请教 [打印本页]

作者: chenfeng2010    时间: 2005-11-25 09:22
标题: 请教
如何将两行数据合并为一行?数据格式如下:
23456789   1   2   3
4
34567890   3   4   5
6
将上列四行排为形如
23456789   1   2   3  4
34567890   3   4   5  6
的数据
多谢。
作者: mocou    时间: 2005-11-25 11:05
  1. sed 'N;s/\n/\r/' file
  2. cat file|xargs -n5
复制代码

作者: lxr01    时间: 2005-11-25 15:21
sed 'N;s/\n/\t/' file




欢迎光临 Chinaunix (http://bbs.chinaunix.net/) Powered by Discuz! X3.2