use strict; use warnings; use 5.010; use CGI qw(); my $date = 'Wed Mar 10 10:10:48 IST 2010'; my @parts = split /[ :]/, $date; my $valueStr = <new (); print $cgi->header (); print $cgi->start_html (); for my $value (@values) { next if $value !~ /_$parts[1]_/; given ($value) { when (/(v09.11-[a-z]\d{3})/) {print $cgi->p ($1); continue}; when (/(v09.10-[a-z]\d{3})/) {print $cgi->p ($1); continue}; when (/(v08.\d{2}-[a-z]\d{3})/) {print $cgi->p ($1); continue}; } } print $cgi->end_html (); #### Content-Type: text/html; charset=ISO-8859-1 Untitled Document

v09.11-s008

v09.10-p002

v08.11-e002