Here's what I've got:
objArray1 = [ { candidate1: "Alex" , votes: 4}, { candidate2: "Paul", votes: 3}];
objArray2 = [ { candidate1: "Alex" , votes: 7}, { candidate2: "Ben", votes: 3}, { candidate3: "Melisa", votes:8 }];
I'm using Javascript to create an array with all the candidates and display the number of votes each one has. Calculating the votes is simple, but combining all the candidates into one array is where I need help.
The final array should include: Alex, Paul, Ben, and Melisa.
Your assistance would be greatly appreciated!