I usually use my eyes to Xd, but this time its not me who needs to count it but functionA. am trying to make a window to draw X amount of button/textfields depending on the contain inside classA, I could just hard code it into the functionA seeing I know whats is inside classA. But that would require me to remodify it everytime I change the nummers of variable inside classA.
Another problem would be that I need to make a functionB for classB which would probably looks identical to functionA except it would draw 1 less button. I don't really mind doing that, but seeing that I have Y classes, I thougth maybe I would spend alot of time in doing a more dynamic way for it now. so I don't need to have 1000 functionAaa to funtionZzz. I remembered that unity had something similar with they scripting where the variable would appear on the editor, so I thougth that they had to know how many varible there was so I tired to google about it, but googling unity really didnt help :l