Cannot Find Symbol
This is a very common issue because all identifiers in Java need to be declared before they are used. When the code is being compiled, the compiler does not understand what the identifier means.
There are many reasons you might receive the “cannot find symbol” message:
- The spelling of the identifier when declared may not be the same as when it is used in the code.
- The variable was never declared.
- The variable is not being used in the same scope it was declared.
- The class was not imported.
0 Comments
Post a Comment