visual basic question on arrays
-
i am in the process of writing a game called bunco and i have hit one of those walls. Basically i have an 12 element array and at the end of the game i need to find out which element holds the highest value,which holds the second highest, and what holds the third highest but i also need to find out if there is a tie for any of those spots now i know the long way to do this but was hoping that someone might know a shorter and more effiecient way
-
i am in the process of writing a game called bunco and i have hit one of those walls. Basically i have an 12 element array and at the end of the game i need to find out which element holds the highest value,which holds the second highest, and what holds the third highest but i also need to find out if there is a tie for any of those spots now i know the long way to do this but was hoping that someone might know a shorter and more effiecient way
If in VB.NET, use Array.Sort. If in VB6, search the web for a sort routine.
It's not the fall that kills you: it's the sudden stop - Down by Law, Jim Jamursch (1986)
-
If in VB.NET, use Array.Sort. If in VB6, search the web for a sort routine.
It's not the fall that kills you: it's the sudden stop - Down by Law, Jim Jamursch (1986)
thats not exactly what im looking for. it is vb6 and the reason i came here was to find some help normally i would just use this one sort function but the problem is the elements in the array are all instances of the player class so not only do i need to find out the 1st 2nd and 3rd place winners but i need to know the names of them which makes it a little more noodle scratching than a normal array and the thing that sucks most is i can see the solution on the back of my brain well anyways if anyone has any ideas