Java List Difference getDiffentElement(List minList, List maxList)

Here you can find the source of getDiffentElement(List minList, List maxList)

Description

get Diffent Element

License

Open Source License

Declaration

public static List<String> getDiffentElement(List<String> minList, List<String> maxList) 

Method Source Code


//package com.java2s;
import java.util.*;

public class Main {
    public static List<String> getDiffentElement(List<String> minList, List<String> maxList) {
        List<String> newList = new ArrayList<String>();
        for (String max : maxList) {
            if (!(minList.contains(max))) {
                newList.add(max);/*  www. j  av  a  2  s .  c  om*/
            }
        }
        return newList;
    }
}

Related

  1. diffList(List aList, List bList)
  2. diffSet(List a, List b)
  3. diffSimple(String name, Object expected, Object actual, List messages)
  4. extractDifference(List l1, List l2, List in1not2, List in2not1, List inBothFrom1, List inBothFrom2, Comparator c)
  5. formatDifferentFileNames(List results)
  6. getDifference(List bigger, List smaller)
  7. getDiffInfo(List infoList)
  8. getLeftDiff(List list1, List list2)
  9. getListsDiffFormatted(List list0, List list1)