Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
Index your code
hub
/
github.com/wangzheng0822/algo
/ checkIndexForAdd
Method
checkIndexForAdd
java/05_array/GenericArray.java:158–162 ·
view source on GitHub ↗
(int index)
Source
from the content-addressed store, hash-verified
156
}
157
158
private
void
checkIndexForAdd(
int
index) {
159
if
(index < 0 || index > size) {
160
throw
new
IllegalArgumentException(
"remove failed! Require index >=0 and index <= size."
);
161
}
162
}
163
}
Callers
1
add
Method · 0.95
Calls
no outgoing calls
Tested by
no test coverage detected