Google Gson - adding arrays to a List
If you are able to use Java 8 you can use streams:

List&lt;String[]&gt; list = IntStream.range(0, 3)
    .mapToObj(i -&gt; new String[] { String.valueOf(i) })
    .collect(Collectors.toList());


Let's break it down:


IntStream.range(0, 3) gives you the values 0, 1 and 2
.mapToObj(i -&gt; new String[] { String.valueOf(i) }) converts them to a string and puts them into a String[]
.collect(Collectors.toList()) collects the stream into a List&lt;String[]&gt;