#!/usr/bin/perl use warnings; use strict; use Date::Format; use Date::Parse; my $thingy = q{NOV-07}; my $time = str2time(qq{1-$thingy}); my $date = time2str(q{%Y/%m}, $time); print $date;