|foo|bar|||baz| #### s{ (?## $row = join "|", map { s/^\s*$/0/; $_ } split( /\|/, $row, -1 );