my @ary = \( &test, &another_test, &third_test ); my $sub_i_want_to_call = $ary[rand(@ary)]; $sub_i_want_to_call->();