Problem with a sequence of variables

Started by degustibus, Sun 26/12/2004 09:07:52

Previous topic - Next topic

degustibus

I've called a sequence of variables num1, num2, num3, num4...
Then I have a function that return an int variable "count"
I'd want to use as a parameter the variable numx where x is the value of "count"
What have I to write in the code to do this?

Doctor Oakroot

Much easier if you use arrays.

int num[10];

num[count]=1; // or whatever you want to do with it.

SMF spam blocked by CleanTalk