What are Variables in Alice (alice.org)?

car-sign-object-alice

To Make a variable, click on the “Make a variable” button

variable-button-in-alice2

Then you have to decide on the type of variable

type-of-variables-in-alice

The “Big” Types of Variables

number = 3.1, 3  , 4.5

boolean = true or false

string = “abc”,   “3.1” ,   “&*(&^”, “true”, “false”, “  ” ”

strings are just things in quotes

 

alice-make-variable-example

 

In order to crete a variable, you click on the “create new variable” button , choose a type and , if you want , give it a value in the method editor.

how-to-create-variable-in-alice

Leave a Reply

Your email address will not be published. Required fields are marked *