in reply to Re^2: Process large text data in arrayin thread Process large text data in array
That is what join is for:
$newline = join "|", map { "$_=$trec{$_}" } keys %trec; [download]