+ 2
Java Output Delay
I have been trying to delay the output in my code but it just shows Time Out and keeps exiting. Do i need to import any package? Are there any other method which carries out the same function? Btw may i know which java version is in this application? THANKS!! Here's my code - try{ System.out.println("Output is "); Thread.sleep(4000); } catch (Exception e) { //nothing }
5 ответов
+ 1
using a value of 2000 gets a timeout, but a value of 1500 works. The system probably has a 2 second execution limit to limit system overload, endless loops, etc.
0
I think in Sololearn, thread sleep don't works....
0
So is there any way in which i can delay the output?
0
On Sololearn you have only 5 seconds before time out.
0
Chris Persichetti
Maybe they reduced the time limit. Connection issues plays also a role.