I want to be able to read from an array a specific set of lines that relate to a certain name I have in another array
for example:
in the names array i have "Ben" stored as the name and i want to see if the other array also contains the name "Ben" and if it does the it will add the scores of each line where "Ben" is mentioned
other array:
"Ben got 5" "Nash got 6" "Ben got 4" "Josh got 1"
so it will only add 5 and 4 to get 9
the program will then save the calculated number to a list.
For Each n As String In commonNames 'for the example the commonNames array contains Ben"
If names.Contains(n) Then
'add each of their scores and divide by how many their are
End If
Next
Console.ReadLine()
For Each n As String In originames
'add each score to the user and divide by 1
any help would be appreciated guys :)