What is the difference between Compile and Submit?

Every problem page has two buttons:

  • Compile and Run
    • When you click this button, the code that you have submitted is tested against the sample input and sample output.
    • This is meant for you to check whether your code is working correctly when it is evaluated against the sample test cases.
  • Submit
    • When you click this button, your code is evaluated against internal test cases.
    • These extensive test cases take your program through rigorous checks to ensure that the code passes all the relevant test cases.