title: How to implement a 2d array of LinkedLists
body: <p>I'm working on implementing an algorithm from a paper. The paper describes using a grid, where each grid square holds a linked list of integers that represent objects in that grid square.</p>
  
  <p>I decided to implement this using <code>LinkedList&lt;Integer&gt;[][]</code>, which of course gives me a <code>generic array creation</code> error. </p>
  
  <p>I can't think of a better way of representing the idea of a grid of linked lists. I also understand that using <code>LinkedList[][]</code> would compile but is bad practice as it is untyped. However, I would prefer not to use <code>ArrayList&lt;ArrayList&lt;LinkedList&lt;Integer&gt;&gt;&gt;</code> because that is unreadable, at least to me. </p>
  
  <p>Is there a way around using an untyped <code>LinkedList</code> here? Or perhaps some other solution?</p>