Java tutorial
//package com.java2s; import java.util.ArrayList; import java.util.Collection; import java.util.List; public class Main { public static <T> List<T> union(Collection<T> a, Collection<T> b) { ArrayList result = new ArrayList(a); result.addAll(b); return result; } }