I figured out open (OUT, ">out.txt") but I'm stuck on how to pass the data into the file.Thank you for answering such a rookie question...#!/usr/bin/perl -w $file = "in.txt"; open (FILE, "$file"); my @results; while (<FILE>) { if (/^N\d+\s+\*(.*)/) { push @results, "!$1"; } else { push @results, /[ABC]([-+]*[\d\.]+)/g; } } print join ' ',@results;
In reply to Creating new file by under_score
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |