复制
收藏
提问
全网
public void checkNumber(int num) { if (num < 0) { throw new IllegalArgumentException("Number must be positive"); } }
刚刚
理解问题public void checkNumber(int num) { if (num < 0) { throw new IllegalArgumentException("Number must be positive"); } }
已完成理解「public void checkNumber(int num) { if (num < 0) { throw new IllegalArgumentException("Number must be positive"); } }」
展开阅读网页
更专业一些
转笔记
专业
public void checkNumber(int num) {
if (num < 0) {
throw new IllegalArgumentException("Number must be positive");
}
}不在提醒