Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.
György Varga19,198 Points
Check my solution please! (Towers are on path)
I've tried to examine if the Towers are on the Path. I wrote a method named 'OnPath' in the 'Path' class for this and in the 'Tower' class I called this method just like we've done it in the 'MapLocation' class. Can you please check it? It compiles, but I don't know if it's correct or not.
Thank you for your help!
James ChurchillTreehouse Teacher
Did you try placing a tower on the path to see if you get the expected exception?