$output = $exp->exp_after(); # and $output = $exp->expect($timeout, [ qr/password/ ]); # and $output = $exp->send("password\n");