Q:

How to grep the word between two symbols in Perl?

I need to grep the word between the symbols as shown below in an array.
my $string = "?hi how r u?what is your name?what is your age?";

It's to be converted to array where array should be like:
my $array[0]="hi how r u";
my $array[1]="what is your name";
my $array[2]="what is your age";

A:

You can use the split function, however you have to escape the ? character, so that it won't get special treatment as part of a regular expression control character.
 my @array = split '\\?', $string;

