Permutation { private Permutation() {} private  Permutation(); static long factorial(final int n); static List<T> permutation(final long no, final List<T> items); @SafeVarargs @SuppressWarnings("varargs") static Stream<Stream<T>> of(final T... items); static Stream<Stream<T>> of(final List<T> items);  }
@Test void permutation0() { assertEquals(Arrays.asList(1, 2, 3), Permutation.permutation(0, LIST)); }
@Test void permutation1() { assertEquals(Arrays.asList(1, 3, 2), Permutation.permutation(1, LIST)); }
@Test void permutation2() { assertEquals(Arrays.asList(2, 1, 3), Permutation.permutation(2, LIST)); }
@Test void permutation3() { assertEquals(Arrays.asList(2, 3, 1), Permutation.permutation(3, LIST)); }
@Test void permutation4() { assertEquals(Arrays.asList(3, 1, 2), Permutation.permutation(4, LIST)); }
@Test void permutation5() { assertEquals(Arrays.asList(3, 2, 1), Permutation.permutation(5, LIST)); }