형변환1 [ Java ] 자바 형변환(문자, 숫자) 안녕하세요. 오늘은 문자, 숫자형을 형변환 하는것에 대해서 설명 드리겠습니다. 1. 문자 > 숫자 1 2 3 4 5 6 // 문자 > 숫자 String text = "100"; int number = Integer.parseInt(text); System.out.println(number); // 100이라는 숫자로 변환. 2. 문자 > Double, Float 1 2 3 4 5 6 7 8 // 문자형을 > Double이나 Float로 변환. String text= "10"; double dou = Double.valueOf(text); // Double float flo = Float.valueOf(text); // Float http://colorscripter.com/info#e" target="_.. 2019. 9. 30. 이전 1 다음