Navigation Menu

Skip to content

Instantly share code, notes, and snippets.

@wviana
Created May 31, 2016 13:30
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wviana/f8d0f8f6a1817f21d3957eb376518580 to your computer and use it in GitHub Desktop.
Save wviana/f8d0f8f6a1817f21d3957eb376518580 to your computer and use it in GitHub Desktop.
Map<Integer, Integer> Result= new HashMap<>();
int condition = Math.max(sample.size(), fileTwo.size());
for(int counter=1; counter<=condition; counter++)
{
int match=0;
for(String fileTwoPostionValue : fileTwo.get(String.valueOf(counter)))
{
if(sample.get(String.valueOf(counter)).contains(fileTwoPostionValue))
{
match++;
}
}
Result.put(counter.toString(), match);
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment