my $string = "a=b c=d"; my @array = split /\s|(?==)|(?<==)/, $string;