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

CSS How to Make a Website Styling Web Pages and Navigation Style the Portfolio

Sovathmonyvann Koch
Sovathmonyvann Koch
455 Points

Need clarify on " Float & Width %"

I watched the video but i m a little confuse how Float & width % work.

Robert Lantry
Robert Lantry
Courses Plus Student 7,723 Points

This is a very basic example of how using float and width % work in conjunction.

http://codepen.io/anon/pen/PqQPKz

As you noticed, there is a 100% total of width, which leaves some white-space for the page, and the second center div is floating to the left as well.

If you have the % go over 100% for one of the elements, It'll then wrap and then nest under the respective div with the same float.

Hopefully this helps give you a little insight on the request!