It took N minutes to finally create an executable JAR file. I am afraid to share it with you.
If you want to download this file, go to http://yourhome.arkoo.com/lilao/a.rar.
 
As a beginner, I prefer the following mistakes:
1) Not all java can be packaged into a jar package, as if there is no frame (not sure)
Because the results run after packaging, there is no display. I tried one and didn't report an error. Maybe if you don't want to give feedback, you can. But I did not try this.
 
2) think that you can double-click the jar package to run it.
Actually not. The executable JAR file must be described in the MANIFEST. MF file with the Main-Class option.
 
3) when explaining the Main-Class, you must specify that you are an entry Class.
I thought it was based on the file directory. In fact, this is only superficial. The first is package. If you do not have a package, you can only put it in the root directory. Only when you have a package can you have a corresponding folder. In this way, the main-class is located by folder. If one item does not match, neither can it be done. "cocould not find the main class. Program will exit!" may occur !" .