Here you can find the source of fill(final double[][] arr, final double val)
Parameter | Description |
---|---|
arr | array to fill |
val | value to fill the array with |
public static double[][] fill(final double[][] arr, final double val)
//package com.java2s; //License from project: Open Source License import java.util.Arrays; public class Main { /**// w w w . j a va 2s. com * Fills the given two-dimensional {@code double} array with the value * {@code val}. * * @param arr array to fill * @param val value to fill the array with * @return filled array */ public static double[][] fill(final double[][] arr, final double val) { for (final double[] line : arr) { Arrays.fill(line, val); } return arr; } }