I have written a program that consists of roughly 3000 lines of code. The program works correctly to my knowledge. Is there any tool available which I can download that will help me verify my code is working correctly as well suggest how to optimise it?
Thanks
For verifying you should consider writing tests. JUnit would be the obvious choice for that. TestNG a popular alternative.
For optimising, you might consider checkstyle, findbugs and PMD. Won’t do much for performance, but might give some hints for general improvements of code style.
If you are really concerned about performance you might consider a profiler. Just google profiler + java and the IDE of your choice to find appropriate tool support.
But don’t forget: premature optimization is the root of all evil.