Here you can find the source of fill(final T[] array, final T value)
Parameter | Description |
---|---|
T | Type of array elements |
array | array to fill |
value | value to use |
public static <T> T[] fill(final T[] array, final T value)
//package com.java2s; import java.util.Arrays; public class Main { /**/*from w ww .j av a 2s .c o m*/ * Fill the given array with the given value * @param <T> Type of array elements * @param array array to fill * @param value value to use * @return filled array */ public static <T> T[] fill(final T[] array, final T value) { Arrays.fill(array, value); return array; } }