#Error Cannot Find Symbol
1 messages ยท Page 1 of 1 (latest)
I uploaded your attachments as Gist.
Here is an AI assisted attempt to answer your question ๐ค. Maybe it helps! In any case, a human is on the way ๐. To continue talking to the AI, you can use </chatgpt:1108714622413963314>.
The error "cannot find symbol" typically occurs when the compiler cannot find a particular class, method, or variable that is being referenced in the code. In this case, it seems like the compiler is unable to find the classes or methods named "Withdraw" and "Deposit" in your main file.
There are a few common reasons why this error may be occurring:
-
Missing import statement: Make sure that you have imported the classes that contain the "Withdraw" and "Deposit" methods in your main file. If these classes are not in the same package or are from external libraries, you need to import them using the import statement.
-
Incorrect package name: If the classes containing the "Withdraw" and "Deposit" methods are in a different package than your main file, make sure that you have specified the correct package name when importing them.
-
Typo or misspelling: Check for any typos or misspellings in the names of the classes or methods. The names must match exactly as they are defined in their respective files.
By addressing these potential issues and ensuring that the necessary classes and methods are correctly imported and referenced in your main file, you should be able to resolve the "cannot find symbol" error for "Withdraw" and "Deposit".
Thanks I have found solution for the querry
you could use reentrantreadwritelock for the account btw
acctually i am learning multithreading i have yet to read about it. But thanks for the advice.