in reply to Re: Split on 2nd Occurence
in thread Split on 2nd Occurence

Even this different approach would be clearer with a list slice:

my $prefix = join '.', (split /\./, $ipaddr)[0,1];

    -- Chip Salzenberg, Free-Floating Agent of Chaos