title: How to do a triangular array in Haskell
body: <p>I want to do something like</p>
  
  <pre><code>array ((0,0), (25, 25)) [((i,j), 1) | i &lt;- [0..25], j &lt;- [i..25]]
  </code></pre>
  
  <p>which you can see by the array index, is only defined when <code>i &lt;= j</code>.  However, when I try to print this out in ghci I get an error because it tries to print things like <code>(1,0)</code> due to the array bounds. </p>
  
  <pre><code>((1,0),*** Exception: (Array.!): undefined array element
  </code></pre>
  
  <p>I could just have the array be square and put something like 0's in those entries, but I think that would be suboptimal. Is there a way I can set up the bounds of this array to be "triangular"?</p>