How to get value of variable given name

I need to know a way to find the stored value of a Snap variable given its name. The only way I can think of to do this is to use a JavaScript function to find the value of the variable by doing something like SnapVariablesObject[VariableName].
Can someone tell me object Snap variables are stored in?
(this is my first post here so if the image doesn't work I'll try to reply to this with the image)

There's a library called "create variables" that will do what you're asking. But almost certainly that's the wrong approach to whatever problem you're solving.

For example, if you want to make a hash table, instead of having a variable for each bucket, make a list of however many empty lists you want, and then you can use the number returned by your hash function as an index into the list.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.