Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import java.util.Scanner;
- public class Main {
- /**
- * @param args
- */
- public static void main(String[] args) {
- Scanner in = new Scanner(System.in);
- int x, y;
- while (true) {
- System.out.print("x, y ?");
- try {
- x = new Integer(in.next());
- y = new Integer(in.next());
- break;
- }
- catch (Exception e) {
- continue;
- }
- }
- in.close();
- System.out.println(x);
- System.out.println(y);
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement