in reply to Re: Mr. Ternary is greater than Mrs. If Else
in thread Mr. Ternary is greater than Mrs. If Else
well, overall its all about readability problems with Mr. Ternary...
to easily remember the structure of Mr. Ternary a multi-decision structuring as follows:
<expression> ? eval { <statement>; <statement>; <statement>; <expression> ? eval { <statement>; <statement>; <statement>; } : eval { <statement>; <statement>; <statement>; }; } : eval { <statement>; <statement>; <statement>; <expression> ? eval { <statement>; <statement>; <statement>; } : eval { <statement>; <statement>; <statement>; }; };
NOTE: (eval or \& or do) well also work
literally, Mr. Ternary is more on simple symbols that gives you a more concentration on expressions and statements without being bothered with words like if, elsif, and else.
i don't think so that other languages could make Mr. Ternary more functional (making Mr. Ternary hold multiple-statements) than Perl could do. what do you think?
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: Mr. Ternary is greater than Mrs. If Else
by shmem (Chancellor) on May 20, 2007 at 08:54 UTC | |
by PerlPhi (Sexton) on May 20, 2007 at 10:53 UTC | |
by blazar (Canon) on May 20, 2007 at 13:31 UTC | |
|
Re^3: Mr. Ternary is greater than Mrs. If Else
by blazar (Canon) on May 20, 2007 at 12:54 UTC |