
Code:
int valueOfCoin = validCoins[index].getValue( );
validCoins is a valid array and index is a valid variable containing a number that chooses which line of the array to get the value of.
getValue() is a method within a different class that just returns an integer.
I might not have given enough information to answer this question but anybody have any ideas?