Hi Yang, > sub ok ($;$) { } and sub is ($$;$) { }
Those are subroutines with prototypes. `sub NAME(PROTO)` `sub ok ($;$)` Requires one mandatory argument and an optional one. They are separated by a semi-colon in the prototype definition. The arguments will be considered in scalar context (due to the `$`). `sub is ($$;$)` Requires two mandatory arguments and an optional one. All of them will be considered in scalar context. See `perldoc perlsub` for more information. Regards, Alan Haggai Alavi. -- The difference makes the difference -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/