解决Exception in thread "main" java.lang.Error: Unresolved compilation problem:Syntax error...报错

How to solve the error:

Exception in thread "main" java.lang.Error: Unresolved compilation problem:

Error Syntax, INSERT ";" to Complete AT cn.com.infosec.test.Rsaa.main of Statement (Rsaa.java:157) (thread "main" java.lang.error: Compile unresolved issues exception: Syntax error , insert "(2);", a statement completed cn.com.infosec.test.rsaa.main (rsaa.java:157))

It is a start:

Then I selected the red wavy line deleted just fine, as line 30 is no longer being given.

Obvious error also easy to solve, but hidden bad solved, as follows:

Put the mouse on a red cross place display: Syntax error, INSERT ";" to Complete of Statement (syntax error, insert ";" to complete the sentence)

Executing code after the newspaper

Exception in thread "main" java.lang.Error: Unresolved compilation problem:

Error Syntax, INSERT ";" to Complete AT cn.com.infosec.test.Rsaa.main of Statement (Rsaa.java:157) (thread "main" java.lang.error: Compile unresolved issues exception: Syntax error , insert "(2);", a statement completed cn.com.infosec.test.rsaa.main (rsaa.java:157)) error.

I Baidu a bit, they say the problem is due to jdk version, or create a new class, copy the code in the past just fine, but I changed or not.

After groping quite a long time, only to find the solution:

 As shown above, the image above a blank check, and delete, just fine.

 Summary: Since this is to copy someone else's code on the Internet, so some copy down the code there will be a special character , you need to delete them all. I can not find, knock yourself over the code but to be honest it. In short, we reported this wrong for many reasons, to see if you are the kind of reasons.

Published 57 original articles · won praise 36 · views 60000 +

Guess you like

Origin blog.csdn.net/hqy1719239337/article/details/88708219