in reply to Re^4: cut vs split (suggestions)
in thread cut vs split (suggestions)
Anyway: -n does an unnecessary chomp on every line, so remove that; and use a limit on split: it doesn't actually need to split all 25 fields:
Update: But for<> reads all lines in at ones; you may not want that with large files, so use while <> instead.perl -le 'BEGIN{$,=","} print+(split",",$_,16)[0..14]for <>' numbers.c +sv
|
|---|