#!/usr/bin/perl use strict; use warnings; my $data = 'input.txt'; my $placeholder = ''; unless(open(INPUT, $data)) { die "Can't open input file $data\n"; } # Print heading print "Product Release product Type color basic color all overseas shipping\n"; while(my $line = ) { if($line =~ m/Release Date(\d+)\/(\d+)\/(\d+)/) { print "$line"; } } close INPUT;