Created
November 28, 2011 08:28
-
-
Save mojaie/1399614 to your computer and use it in GitHub Desktop.
Example:Scanner.next
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import java.util.Scanner; | |
public class Main { | |
public static void main(String[] args) { | |
Scanner in = new Scanner(System.in); | |
System.out.println(“単語を2つ入力してください。”); | |
String str1 = in.next(); | |
String str2 = in.next(); | |
System.out.println(“入力した単語1は ” + str1 + ” です。”); | |
System.out.println(“入力した単語2は ” + str2 + ” です。”); | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment