title: Array, quantity of positive and negative numbers must be equal
body: <ul>
  <li><strong>quantity</strong> of positive and negative numbers in array <strong>must be equal</strong>.</li>
  <li>an array mustn't contain <strong>zero</strong>.</li>
  </ul>
  
  <p>The main issue is that array is not always consist of 50/50 of percent of positive and negative numbers. </p>
  
  <p>If you can show me much simply way to code it you are welcome! </p>
  
  <pre><code>public static void main(String[] args) throws IOException {
          int array[] = new int[12];
          int positiveCounter = 0;
          int negativeCounter = 0;
  
          for (int i = 0; i &lt; array.length; i++) {
              array[i] = createRandom();
              while (array[i] == 0) {
                  array[i] = createRandom();
              }
  
              if (positiveCounter &gt; array.length / 2) {
                  array[i] = -1 * array[i];
                  positiveCounter--;
                  negativeCounter++;
              }
              if (negativeCounter &gt; array.length / 2) {
                  array[i] = -1 * (-array[i]);
                  negativeCounter--;
                  positiveCounter++;
              }
  
              if (array[i] &gt; 0) {
                  positiveCounter++;
              }
              if (array[i] &lt; 0) {
                  negativeCounter++;
              }
          }
          System.out.println(Arrays.toString(array));
          System.out.println("Pos: " + positiveCounter);
          System.out.println("Neg: " + negativeCounter);
      }
  
      static int createRandom() {
          Random random = new Random();
          int x = -10 + random.nextInt(11 - (-10));
          return x;
      }
  </code></pre>