title: Calculate the 'center of an array' in Java
body: <p>this is my question: </p>
  
  <p>Given an  int array of length=6, i'd would like to know which pair of numbers that belongs to the array, is the center of it. That means that if you divide the array into 3 smalls arrays of length==2, and if you put them as single pair of coordinates in a matrix, (where the first coordinate means the value of the i, and the second one means the value of the j), you would get something like an "L", on your matrix. So, the center is the small coordinate of length=2 that's in the midle of the L. I know it's pretty confusing, so here's an image:</p>
  
  <p><img src="https://i.stack.imgur.com/LnWzc.png" alt="grid"></p>
  
  <p>PD: the only pair of "small arrays" available are: </p>
  
  <pre><code>{array[0],array[1]}
  
  {array[2],array[3]}
  
  {array[4],array[5]}
  </code></pre>
  
  <p>Hope you can help me! I'm making the logic of a game! Sorry for my English!</p>