Bennett Todd wrote: > > my @categories = qw(ALPHA BETA); > my($pat) = qr(@{[join('|', @categories)]}); my $pat = do { local $" = '|'; qr(@categories) }; Or, of course: sub make_pat(@) { local $" = '|'; qr(@_) } my $pat = make_pat @categories; -- John Porter ==== Want to unsubscribe from Fun With Perl? Well, if you insist... ==== Send email to <fwp-request@technofile.org> with message _body_ ==== unsubscribe