Alice Community  

Go Back   Alice Community > Alice 2 > How do I...?

Thread Tools Display Modes
Select/Case versus If/Else
Posts: n/a
Post Select/Case versus If/Else - 10-12-2010, 07:40 AM

Does Alice 2.2 have an equivalent to the general Select-Case control structure that other languages have?

I want to do an action based on a bunch of possible cases.

I know it can be done with multiple If/Else, but I'd rather the neater Select/Case

Just wondering. haven't found it yet.
Reply With Quote
Super Moderator
x2495iiii's Avatar
Status: Offline
Posts: 3,508
Join Date: Dec 2008
Location: Somewhere in the Continental U.S.
Default 10-12-2010, 10:26 AM

Not that I know of.

It'll have to be the if/else if method, though you can make it easier if you can find a way to make everything dependent on one number variable, that way your conditional arguments closely resemble a case switch statement.
Reply With Quote

if/else, select/case, selection structures

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Copyright ©2020, Carnegie Mellon University
Alice 2.x 1999-2012, Alice 3.x 2008-2012, Carnegie Mellon University. All rights reserved.