In C/C++ I used to do
C/C++
int arr[10] = {0};
...to initialize all my array elements to 0.
Is there a similar shortcut in
Yet another approach by using lambda above java 8
Arrays.stream(new Integer[nodelist.size()]).map(e -> Integer.MAX_VALUE).toArray(Integer[]::new);