Answer: meanscannot find the path or configuration
You can try to modify the path or check the environment variables to solve the problem.
method one:
1. If there is a ".class" suffix when compiling, delete it.
2. If it still doesn't work, enter "java file name" at the current location and recompile.
Method Two:
1. If there is no need to delete the package line.
2. Return to the previous package directory.
3. Then enter "java package.package.package...file" and compile.
The above is the detailed content of How to solve the problem that Java cannot find or cannot load the main class. For more information, please follow other related articles on the PHP Chinese website!