public class VarargMethod { void test() { List list = new ArrayList<>(); list.add(String.format("m", p1, p2)); } }