Here's my answer from your
duplicate thread on this topic:
There are only certain method calls that can throw it, and you'll know when you call one of them, because InterruptedException is a checked exception, so the compiler will require you to declare or catch it.
The exception is thrown when some other thread calls
Thread.interrupt() on your thread while it is blocked on one of those methods (such as
wait()).
In the future, please
UseOneThreadPerQuestion.(⇐click)