Quantcast
Channel: If...else if...else in REBOL - Stack Overflow
Viewing all articles
Browse latest Browse all 4

Answer by Graham Chiu for If...else if...else in REBOL

$
0
0

You can use the case construct for this, or the switch construct.

case [   condition1 [ .. ]   condition2 [ ... ]   true [ catches everything , and is optional ]]

The case construct is used if you're testing for different conditions. If you're looking at a particular value, you can use switch

switch val [   va1 [ .. ]   val2 [ .. ]   val3 val4 [ either or matching ]]

Viewing all articles
Browse latest Browse all 4

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>