◽ JSP
2019. 5. 23.
02:11
next() - 객체 값 출력 ( result.next()와 혼동 유의! )
package Test1;
import java.util.Scanner;
public class exercise {
public static void main(String[] args) {
Scanner a = new Scanner(System.in);
String test1;
System.out.println("Scanner a = new Scanner(System.in);");
System.out.print("a값 입력하기 : ");
test1 = a.next();
System.out.println("a:" + a);
System.out.println("");
System.out.println("======================================================");
System.out.println("");
System.out.println("test1 = a.next()");
System.out.println("test1 : " + test1);
}
}
실행화면

'◽ JSP' 카테고리의 다른 글
웹 애플리케이션 구조 (0) | 2019.06.03 |
---|---|
(임시) serialVersionUID = 1L; 뜻 (0) | 2019.06.03 |
request() 2) getParameter(name) - 폼값 받기 (0) | 2019.05.23 |
Scanner s=new Scanner(System.in) - 값을 받는다. (0) | 2019.05.22 |
e.printStackTrace() - 에러 메세지 출력 (0) | 2019.05.21 |
Statement - excuteUpdate, executeQuery, execute (0) | 2019.05.21 |
PreparedStatement - statement와 가장 큰 차이점은 "?" 처리 가능 (0) | 2019.05.21 |