Welcome to the Treehouse Community

Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community! While you're at it, check out some resources Treehouse students have shared here.

Looking to learn something new?

Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.

Start your free trial

Java Java Data Structures - Retired Exploring the Java Collection Framework Using ArrayLists

Compiler error

https://w.trhou.se/nhrrg6rz6y I have 6 errors that stem from line 16 and 17 of my Example class, can someone help?

3 Answers

Kevin Faust
Kevin Faust
15,353 Points

I dont see a "getHashTag()" method in your Treet class. I think you are trying to call the "getWords()" method in your Treet class.

You also have two similar methods in your Treet class which I dont think is right: I see "getWords()" and "geWords()

The second method I believe is mispelled. But im not sure why you have that in the first place anyways. Make sure your code aligns up to what is in the video.

I went back to fix my treet class https://w.trhou.se/begbwala5r but still got the exact same on line 16 and 17 of my Example class

Kevin Faust
Kevin Faust
15,353 Points

This is from your example class:

for (String hastag   /* you missed spelled << */ : originalTreet.getHashTags()){    
    System.out.println(hashtag);
  }

As you can see, you mispelled "hashtag"

Everything else looks fine now. But if you still have an error, copy and paste the exact errors because as of now that is the only thing i can see wrong.

Thanks for the correction notice. I can't copy and paste the entire error message from the workspace console. Do you have a solution for this? It says Example class line 16 identifier @ the (, illegal start @ ". In line 17 it states illegal start of type.