5

which is equivalent in java to "exit(0)" in c

2 Answers 2

11

System.exit(0)

3
  • 3
    Damn, you were faster ... but I added the links ;-)
    – Riduidel
    Jul 16, 2010 at 13:38
  • 1
    Rack it. There is no such thing as exit() "in C". exit() is a system call. You can use the system call from any language capable of linking to it. Please try not to be one of thse C coders who thinks the whole operating system is part of the C language.
    – T.E.D.
    Jul 16, 2010 at 13:49
  • @Carl Smotricz: Lol. That has to be one of my favorite comments ever.
    – T.E.D.
    Jul 16, 2010 at 17:55
1

System.exit(0) just do it

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.