I am writing a code to return multiple values from two arrays simultaneously. I understand since I mentioned only one uint and one address as arguments in returns
, the for loop is throwing an error. What can I do to be able to return multiple values from both the arrays? Following is my code snippet:
function listBest() public view returns(uint, address){
for(uint p = 0; p < number; p++) {
return(listScores, listScoredPeople[p]);
}
}