What does all variable name does exist in this context mean?

why does this message keep happening when my code is run? I am trying to use a list as my parameter can someone please help.

i think you renamed your variables at some point, you're setting "allscores", with a lowercase s, but later trying to use "allScores", with an uppercase s.

you don't need to use camelcase/pascalcase for variables in snap, you can just use spaces to make it easier to read

thank you for the help but I have one last question
I am trying to add all of the elements from "allscore" to HighScores but when i run the code in snap the values aren't being add to the HighScores, what can i do to fix this error?
The part of the code that i am talking about the first part in the procedure "for each item in HighScores

If you have more questions,you can either not mark posts as solution or make a new topic.
People will not look at solved stuff.

There is a place that annoys me very much:your selection sort.
You sould use the builtin sorting blocks in list utillties.

the ADD block puts a value onto the end of a list, changing that list.
the FOR EACH block goes through each item of the list.

why would you add more items onto a list depending on what's in the list? if you're going through the list, and you add items, will the loop also give the items you just added?


Rule number one on using the for loop:No mangling the stuff you are iterating.

Dude, that is so not true. You looked at a solved topic, I looked at a solved topic, and @sarpnt looked at a solved topic. It's also easy to miss the solved indicator. Sometimes people even continue a disscusion after it's been solved, which has happened a lot on this forum.