in reply to How do I use a regex to parse $x = system

system returns a code indicated whether or not it succeeded. Since you want to capture the output, use backticks:
my $whatisit = `whatis grep`;