Skip to content

Instantly share code, notes, and snippets.

View gist:488217
#!/usr/bin/perl
use strict;
use warnings;
my $x = [qr/([aieou]+)/io, qr/(\d+)/o]; #<- Here is a list of 2 regexes...
my $line = <STDIN>;
foreach my $regex (@{$x}) {
if ($line =~ $regex) {
print "a vowel or digit!\n";