#java guidance

1 messages · Page 1 of 1 (latest)

vernal scaffold
#

Is there anyone willing to help guide/support me while I screen share in the study room for this project on methods and arrays?
It is much appreciated as my instructor gives zero feedback.

turbid islandBOT
#

<@&987246399047479336> please have a look, thanks.

turbid islandBOT
#

While you are waiting for getting help, here are some tips to improve your experience:

Code is much easier to read if posted with syntax highlighting and proper formatting.

If nobody is calling back, that usually means that your question was not well asked and hence nobody feels confident enough answering. Try to use your time to elaborate, provide details, context, more code, examples and maybe some screenshots. With enough info, someone knows the answer for sure.

Don't forget to close your thread using the command </help-thread close:1027500463647621170> when your question has been answered, thanks.

pure seal
#

u will get much better feedback if u share some details

#

otherwise people dont even know what they signed up for or whether they could actually help u or not

#

that said, people here dont do VC that much. so if u still get no responses, id suggest to switch to chat

vernal scaffold
#

this is what I am given: greatestWinIndex = getLargestWinIndex(localScores, opponentScores, numGames);

#

this is the code I typed:
private static int getLargestWinIndex(int[] localScores, int[] opponentScores, int numGames) {
int greatestWinIndex = 4 ;
for (int i = 0; i < numGames; i++){
if (localScores[i] > greatestWinIndex && opponentScores[i] < greatestWinIndex)
greatestWinIndex =localScores[i];

    }
    return greatestWinIndex;
}
turbid islandBOT
vernal scaffold
#

arrays:
int[] ourScores = { 19, 18, 10, 11, 43, 24, 38, 34, 33, 10 };
int[] theirScores = { 23, 9, 10, 6, 13, 8, 24, 7, 19, 22 };

turbid islandBOT
vernal scaffold
#

The code I typed is wrong;
My question:

#

How do you display localScores, opponentScores, numGames; in a method that is an array/ but trying to find the high score in localScores(array1) that displays the element and opponentScores from array 1 element