Java Array Fill fillArray(int[] array, int value)

Here you can find the source of fillArray(int[] array, int value)

Description

fill Array

License

Open Source License

Declaration

public static void fillArray(int[] array, int value) 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

public class Main {
    public static void fillArray(int[] array, int value) {
        array[0] = value;//from  www.j  a  v a  2 s  . com
        System.arraycopy(array, 0, array, 1, array.length - 1);
    }

    public static void fillArray(boolean[] array, boolean value) {
        array[0] = value;
        System.arraycopy(array, 0, array, 1, array.length - 1);
    }
}

Related

  1. fillArray(float[] batchVertices, float f)
  2. fillArray(int arrayLength)
  3. fillArray(int min, int max)
  4. fillArray(int size, Float value)
  5. fillArray(int value, int length)
  6. fillArray(int[] nums)
  7. fillArray(Object array, int value)
  8. fillArray(Object[] array, Object value)
  9. fillArray(Object[] objects, Object object)