1. static 해
4. try ~ catch
5. try~catch~finally
>
- static 클 클 호.
2. Math클 클 Wrapper 클
- Math클 함 .
3. static import
- abs() : 한.
- sqrt() : 한.
- max(), min() : / 한.
- round() : 한.
- pow() : 한.
- PI : 파
- Wrapper클(Integer, Double, Character...)
- sqrt() : 한.
- max(), min() : / 한.
- round() : 한.
- pow() : 한.
- PI : 파
- parseXXX : String 형태 환한.
- toString : 한 형태 환한.
- toString : 한 형태 환한.
- 클 .....
> 2 해 하 해 .
~java public class ExceptionExample { public static void main(String[] args) { try { int a = Integer.parseInt(args[0]); int b = Integer.parseInt(args[1]); System.out.println(a + " / " + b + " = " + (a / b)); } catch(ArrayIndexOutOfBoundsException e) { System.out.println(" 2 "); } catch(ArithmeticException e) { System.out.println("0 "); } catch(NumberFormatException e) { System.out.println(" "); } } }
- try ~ catch 행 finally 행한.
6. 클 Exception
- Exception클 .
- Exception 할 .
7. throws / throw
- Exception 할 .
throws : 함 하 한.
throw : 키 할 한.
> 100 키 해 .
throw : 키 할 한.