Serializablepublic class Distributor extends Object implements Serializable
| Modifier and Type | Field | Description |
|---|---|---|
private int |
capacity |
Capacity of the array
|
int[] |
order |
Shuffled sequence of index numbers
|
| Constructor | Description |
|---|---|
Distributor(int range) |
For any number N < range, there is N+1 copies of it in the array, distributed as evenly as possible
|
| Modifier and Type | Method | Description |
|---|---|---|
int |
next(int index) |
Advance the index
|
int |
pick(int index) |
Get the next number according to the given index
|
public int[] order
private int capacity
Copyright © 2020 OpenNARS. All rights reserved.