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

Python Python Basics (2015) Letter Game App Letter Game Refinement

Enzie Riddle
.a{fill-rule:evenodd;}techdegree seal-36
Enzie Riddle
Front End Web Development Techdegree Graduate 19,278 Points

Clear() Function

When we begin refining the entire code, we use clear() a lot when we create new variables. Can someone tell me why? PLEASE answer in a way that is easy to understand: I haven't been doing this long. Thanks!

1 Answer

Keep in mind that this program is going to be printing off a lot of things in the terminal. To keep things from getting cluttered, we want to clear out the space every once in a while. Basically, the clear function here helps to make things nice and tidy.