my $inLine = "RPC, rpc #001b, (1987)"; my ($year) = $inLine =~ /\((\d+)\)/; die "No year found in '$inLine'\n" unless defined $year;