You are viewing a single comment's thread. Return to all comments →
Here is c#!
static List compareTriplets(List a, List b) { List score = new List( new int[]{0, 0}); int i =0;
for(i=0; i<count(a);i++){ if(a[i]>b[i]){ score[0]+=1; }else if(a[i]==b[i]){ score[0]+=0; score[1]+=0; }else{ score[1]+=1; } } return score; } static int count(List<int> aList){ int counter = 0; foreach(var item in aList){ counter++; } return counter; }
Seems like cookies are disabled on this browser, please enable them to open this website
Compare the Triplets
You are viewing a single comment's thread. Return to all comments →
Here is c#!
static List compareTriplets(List a, List b) { List score = new List( new int[]{0, 0}); int i =0;