- import java.io.Console;
- public class A {
- public static void main(String[] args) {
- String str1, str2
- Console c=System.console();
- System.out.print("Enter your account: ");
- str1=c.readLine();
- System.out.print("Enter your password");
- str2=c.readLine();
- System.out.println("Your account: "+str1);
- System.out.print("Your password: "+str2);
- }
- }
複製代碼 |