lionz - Awesome, a thousand thanks!
There is a hidden coin you can collect in each level and I use an array to set the animation of the coin in the menu screen. If you have collected the coin in level 1 then I set X 0 to 1. Coin in level 2 I set X 1 to 1 and so on. There are 10 levels in each world and I want it to show, for example "You've collected 8 out of 10 coins". I have a sprite font and I want to set the text of the sprite font to the x value 0-9.
You've collected "array x 0-9" out of 10 coins.
I know how to do this for each x but not only for 0-9. I want this because in the menu of world 2 to I want to do the same but for x 10-19.