Time for an 2014 update…
This commit is contained in:
parent
372c577f83
commit
09687c4926
2520 changed files with 34227 additions and 7318 deletions
11
Task/User-input-Text/Deja-Vu/user-input-text.djv
Normal file
11
Task/User-input-Text/Deja-Vu/user-input-text.djv
Normal file
|
|
@ -0,0 +1,11 @@
|
|||
input s:
|
||||
!print\ s
|
||||
!decode!utf-8 !read-line!stdin
|
||||
local :astring input "Enter a string: "
|
||||
true
|
||||
while:
|
||||
try:
|
||||
to-num input "Enter the number 75000: "
|
||||
/= 75000
|
||||
catch value-error:
|
||||
true
|
||||
|
|
@ -1,10 +1,11 @@
|
|||
import java.io.BufferedReader;
|
||||
import java.io.InputStreamReader;
|
||||
import java.util.Scanner;
|
||||
|
||||
public class GetInput {
|
||||
public static void main(String[] args) throws Exception {
|
||||
BufferedReader sysin = new BufferedReader(new InputStreamReader(System.in));
|
||||
int number = Integer.parseInt(sysin.readLine());
|
||||
String string = sysin.readLine();
|
||||
Scanner s = new Scanner(System.in);
|
||||
System.out.print("Enter a string: ");
|
||||
String str = s.nextLine();
|
||||
System.out.print("Enter an integer: ");
|
||||
int i = Integer.parseInt(s.next());
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue