You are viewing a single comment's thread. Return to all comments →
This was my original solution:
public class Solution { public static void main(String[] args) { try{ Scanner scan = new Scanner(System.in); int i = scan.nextInt(); double d =scan.nextDouble(); scan.useDelimiter("\n"); String s = scan.next(); scan.close(); System.out.println("String: " + s); System.out.println("Double: " + d); System.out.println("Int: " + i); }catch(Error e){ System.out.println("something went wrong:" +e); } } }
I'm not really sure why this doesnt satisfy the test cases, although it prints as expected
Seems like cookies are disabled on this browser, please enable them to open this website
Java Stdin and Stdout II
You are viewing a single comment's thread. Return to all comments →
This was my original solution:
I'm not really sure why this doesnt satisfy the test cases, although it prints as expected