Here you can find the source of fillArray(int min, int max)
Parameter | Description |
---|---|
min | a parameter |
max | a parameter |
public static int[] fillArray(int min, int max)
//package com.java2s; /******************************************************************************* * Copyright (c) 2014 Open Door Logistics (www.opendoorlogistics.com) * All rights reserved. This program and the accompanying materials * are made available under the terms of the GNU Lesser Public License v3 * which accompanies this distribution, and is available at http://www.gnu.org/licenses/lgpl.txt ******************************************************************************/ public class Main { /**/*www. j av a 2 s. c om*/ * Create a filled array with values going from min to max-1 * (i.e. min is inclusive but max is exclusive). * @param min * @param max * @return */ public static int[] fillArray(int min, int max) { int nb = max - min; int[] ret = new int[nb]; for (int i = 0; i < nb; i++) { ret[i] = min + i; } return ret; } }