Explain the following jumping statement: Exit ()
Advertisements
प्रश्न
Explain the following jumping statement:
Exit ()
स्पष्ट कीजिए
Advertisements
उत्तर
In Java, the System.exit() method is used to terminate the execution of a program immediately. It stops the Java Virtual Machine (JVM) and ends the program, regardless of where it is called.
The statement System.exit(0); indicates normal termination of the program, while a non-zero status value generally indicates abnormal termination.
shaalaa.com
क्या इस प्रश्न या उत्तर में कोई त्रुटि है?
