ⓘ This web page is about the old AlgoSim 2 software. Perhaps you are looking for the new Algosim 3 application?
AlgoSim
Homepage | Screenshots | Gallery of Visualisation | User's Guide | Function Reference | Download | FAQ | Support | Bugs and Solutions | Donate

Reference: createStruct

createStruct(I1, V1, I2, V2, ..., In, Vn) creates a structure with identifiers I1, I2, ..., In with values V1, V2, ..., Vn. Every Ik must be a string (and a valid identifier), and every Vk must be a number, a string, a boolean, or another structure.

Examples:

createStruct("firstName", "Andreas", "lastName", "Rejbrand", "yearOfBirth", 1987, "IQ", ∞)

firstName: Andreas
lastName: Rejbrand
yearOfBirth: 1987
IQ: ∞

createStruct("date", date(0), "time", time(0))

date:year: 2010
date:month: 6
date:day: 23
date:weekOfYear: 25
date:dayOfYear: 174
date:dayOfWeek: 3
time:hour: 15
time:minute: 3
time:second: 43
time:millisecond: 192

ans:time:millisecond = 192