Re: Java Programming help
Please use code tags when posting code.
The problem is down to an extra opening curly brace between the class declaration and the main method, and presumably there's and extra closing curly brace at the end of the file.
Re: Java Programming help
Ok I tried what you suggested and I get a new error now.
c:\solution\java>javac Ch7Ex12.java:98: reached end of file while parsing
Im sorry if this seems like a newb mistake but I have been having issues all semster and just want to get it correct. Thanks
Re: Java Programming help
Quote:
Originally Posted by
lunchbox2626
Ok I tried what you suggested and I get a new error now.
c:\solution\java>javac Ch7Ex12.java:98: reached end of file while parsing
This is the same kind of thing - your curly braces are not matched. The compiler fell off the end of your code looking for the closing brace.
Hint: when opening curly braces, always put in the closing brace at the same time, then code between them. This way they will always match up.
The sooner you start to code, the longer the program will take...
R. Carlson
Re: Java Programming help
Quote:
Originally Posted by
dlorde
Hint: when opening curly braces, configure your IDE to put in the closing brace at the same time, then code between them. This way they will always match up.
Fixed.
Re: Java Programming help
Quote:
Originally Posted by
Deliverance
Fixed.
Yup - I guess there's no good reason not to use a decent IDE, and if you're going to use one, make use of its facilities.
The tools we use have a profound (and devious!) influence on our thinking habits, and, therefore, on our thinking abilities...
E. Dijkstra
Re: Java Programming help
how did you get rid of it