• + 2 comments

    Hi everyone i am new to this and since i wanted to know that i have solved this problem taking input in a same way as it is shown in the sample input and output of this problem. it works well and gives the same output for the sample input. but the problem is that when i pasted this program in the page and tried to run it gives an error like this...

    Exception in thread "main" java.util.NoSuchElementException: No line found at java.util.Scanner.nextLine(Scanner.java:1585) at Solution.getrange(Solution.java:19) at Solution.main(Solution.java:91)

    though everything works well in my computer and gives a proper output. please help if u have any idea regarding this. Thanks.