#!/usr/bin/perl use warnings; use strict; for my $file ( ) { if ( -M $file > .5 ) { unlink $file or warn "Cannot delete '$file' because: $!"; } }