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.
HI all just another person looking for feedback, please be gentle!
Steven Parker221,082 Points
Looks like you're off to a good start! But I wasn't quite sure if you were simply experimenting with different ways of doing things or not. In case not, here's a few suggestions for future projects:
- if you make some inputs case-insensitive, it might make sense to make them all that way
- the same case insensitivity trick can also prevent needing to compare to multiple answer versions
- you can save on numeric conversions by just comparing to strings (like:
mathAdd == "4")
- in an "else if" chain, the last term can be a plain "else" since all other cases have been handled
- inequalities can save needing multiple comparisons (like "
else if (right >= 3)")