my @params = ...; # whatever sets the context... if ( my $x = function_1( @params )) { # do something with the return value from function_1 } elsif ( $x = function_2( @params )) { # do something with the return value from function_2 } # ... and so on.