my $x = "the quick brown fox";
$x =~ s/brown/gray/;  #substitute the word brown with gray, if found
if ($x =~ s/quick/slow/) { #substitute if quick is found & do the block
    print "we did the substitution\n";
}
