I usually use fx-5800P and there is no 'ElseIf' available, I think it's same with fx-9860GII or fx-cg10.
E=3=>Goto 3 E=2=>Goto 2 E=1=>Goto 1 E=0=>Goto 0 Goto Z Lbl 3 [process 3] (Goto Z) Lbl 2 [process 2] (Goto Z) Lbl 1 [process 1] (Goto Z) Lbl 0 [process 0] (Goto Z) Lbl Z [process Z]
(Goto Z) is not necessarily used just like 'break;' with switch() in C-Language, but Goto Z and Lbl Z must be used to avoid 'spaghetti'.
I usually use this for exception handling in CasioBasic. The variable E is an exception flag.
There are many arguments about goto, but I believe this usage in CasioBasic counts for high readability and minimal bug creation.
Is there some good idea for multiple conditional branch in CasioBasic?
Edited by Krtyski, 21 February 2014 - 02:36 PM.