I have 2 int lists which i need to compare the values and see if they are all equal to one another if they are then i want to switch a bool to true otherwise i want that bool false.
Would anyone know the correct code to do this?
Elaboration –
i am using the 2 int lists to see if i have met costs for building resources
one list, currentResources and the other, requiredResources if all values in currentResources are equal to there counterparts within requiredResources i want my bool buildingCompleted to be true
if any one of these values is below there counterpart i want buildingCompleted to be false.
the way these are compared would be the same as their order so requiredResources[0] is compared to currentResources[0], tried searching but i can’t seem to word the question in a way that i find answers.
so if anyones has or knows where i can find one i’d be very greatful.