title: What is the difference between exit(0) & exit(1) used in PERL?
body: <p>So, I came across a <strong>PERL</strong> script while working on an already implemented project. Since its confidential, I cannot reveal much details but the code is somewhat like this :</p>
  <pre><code>if(defined($x)){
      exit(0);
  }
  #...........
  #.some other code.
  #...........
  
  if(!defined($y)){
        print &quot;ERROR !&quot;;
        exit(1);
  }
  </code></pre>
  <p>I am assuming exit(1) is in error conditions and exit(0) is for success cases. But since we are already printing the error message, what is the difference here between <strong>exit(0)</strong> and <strong>exit(1)?</strong></p>