What is the main file for Pascal? Why do I get "Unknown main file"?

Modified on Sun, 21 Feb, 2021 at 8:23 PM

The main file is the file containing the entry point (main program) of your solution. A program is code starting with a

program programname;

declaration.


As you can submit multiple files, there can potentially be multiple such programs. Therefore you need to specify which file contains the main program we should use. Note that the main file must contain the full name of the file (i.e. not the program itself).


Specifying the wrong main file will give you a Compile Error telling you what happened.


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article