Specific numbers have specific colors

Hey there! Sorry for my english at first!
I’ve spent a lot of time googling around. The problem is, I don’t know, how to describe the problem or how to search this problem. I’d like to explain, what I was trying to do, maybe somebody can help me. I’m totally knew to all that programming stuff, so sorry for asking dumb questions.
I would like to show numbers in six different textfields. The number converted in a String should displayed in a specific color depending on the number. So for example: number 1, 3, 4, 6 & 8 should be displayed in green and number 2, 5, 7, 9 & 10 in red.
→ So I do a randInt (eg. 5), and this should displayed in all my textfields as an red 5.

Thank you for your help!
kind regards!

You could have an array of colors where each element has the color corresponding to its index (starting at zero). I assume the list of numbers is limited in size.