题解 | #浮动和清除浮动#
浮动和清除浮动
http://www.nowcoder.com/practice/88bcbaee954349f5a8810bfa94ee61a8
<html>
<head>
<meta charset=utf-8>
<style type="text/css">
.wrap {
/*补全代码*/
height: 100px;
clear: both;
}
.left {
width: 100px;
height: 100px;
/*补全代码*/
float: left;
}
.right {
width: 100px;
height: 100px;
/*补全代码*/
float: left;
}
</style>
</head>
<body>
<div class='wrap'>
<div class='left'></div>
<div class='right'></div>
</div>
</body>
</html>