【LeetCode-Java】常用API 1. 如果返回值是 int[], 那么可以这么初始化: return new int[]{ele1, ele2,...}; 2. 如果需要返回Exception, we can use IllegalArgumentException.