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 trialgabrielalcaraz
7,694 Pointsis this wet code
this code is very repetitive and it looks like it it not following D.R.Y (don't repeat yourself) is or is this not wet code?
1 Answer
Ole Vølund Skov Mortensen
27,842 PointsMy thoughts Exactly!!!
It's very wet. how can someone copy and paste the ones method instead of just make ONE method with name that explained the purpose of it, and force the user to provide a value rather than making 6 methods that all do the same. the value of one method should just be provided by the function caller, not the program. Let humans inject the number and not the program. That's what humans are for-- providing input. Not machines. CP makes me insane when I see it in code
Andrea Wiley
Python Development Techdegree Graduate 10,888 PointsAndrea Wiley
Python Development Techdegree Graduate 10,888 PointsWhat code are you talking about?