Java tutorial
//package com.java2s; import java.util.*; public class Main { public static <A> Set<A> set(A... a) { Set<A> set = new HashSet<A>(); Collections.addAll(set, a); return set; } }