Some problems are so complex that you have to be highly intelligent and well informed just to be undecided about them. - Laurence J. Peter
Originally posted by Dave DiRito:
...VowelCount.java:37: cannot find symbol
symbol : method length()
location: class char[]
for(int i = 0; i <= vowels.length(); i++){...
Originally posted by Dave DiRito:
...VowelCount.java:39: char cannot be dereferenced
if(s.charAt(j).equals(vowels[i])){...
"We're kind of on the level of crossword puzzle writers... And no one ever goes to them and gives them an award." ~Joe Strummer
sscce.org
There are only two hard things in computer science: cache invalidation, naming things, and off-by-one errors
Bill Shirley - bshirley - frazerbilt.com
if (Posts < 30) you.read( JavaRanchFAQ);
"The differential equations that describe dynamic interactions of power generators are similar to that of the gravitational interplay among celestial bodies, which is chaotic in nature."
Well done.Originally posted by Dave DiRito:
Campbell said to use strings throughout. Campbell, are you saying that I should change the char vowell array into a string array of single character strings?
Dave
== only works on actual primitives, for everything else it is likely best to try .equals( ... ); method of whatever you are trying to test.
SCJP 1.4, SCWCD 1.3, SCBCD 1.3
Without deviation from the norm, progress is not possible - Zappa. Tiny ad:
Smokeless wood heat with a rocket mass heater
https://woodheat.net
|