while (<>) { substr($_, 24, 0, ' '); print; } #### $ perl -i~ -pe "substr($_, 24, 0, ' ')" your_file_name_here