VS running multiple main function source files in a project results in an error "The system cannot find the specified file"

VS under a project run multiple main function source file conflict
problem
to learn C ++ process, often write small case code in the next project will create more than one source file to compile and run, each source file by the main function, often Conflict, in the beginning, just changed main to main1, main2..., and later checked, there are several ways to solve this problem.

Solution
1. Remove
Remove the source files that do not need to be compiled.
2. Do not participate in the generation
. Right-click on the source file that is not expected to be generated -> Exclude from generation
————————————————
Copyright statement: This article is the CSDN blogger "CHN_陈The original article of "Hao Nan" complies with the CC 4.0 BY-SA copyright agreement. Please attach the link to the original source and this statement for reprinting.
Original link: https://blog.csdn.net/qq_24123029/article/details/103910061

Guess you like

Origin blog.csdn.net/jccc39/article/details/106414861