配列を反復処理して特定のインデックスに値を配置するときに、範囲外の例外をスキップして次の項目に移動する方法がJavaにあるかどうか疑問に思っていました。
例えば、
for (int x = 0; x <= array.length; x++)
{
for (int y = 0; y <= array[0].length; x++)
{
// code that determines where to put things and in what indices
//if this index is out of the array bounds, I want to forget about it and keep going through the loops
}
}
}