I recently created a basic HTML layout;
<div style="float:left;width:100px;background-color:red">RED</div>
<div style="background-color:blue">BLUE</div>
What I noticed is that when the width of the second DIV is not set or is set in percentage, both DIVs appear on the same line. However, if I specify the width in pixels, the second DIV moves to the next line.
I tried searching for an explanation for this behavior but couldn't find any. I tested it on both Chrome and Firefox browsers.
Check out the demo on JSFiddle