<!DOCTYPE html> <html> <head> <meta charset="UTF-8"> <title></title> <link rel="stylesheet" href="CSS/mycss9.css" type="text/css"> </head> <body> <div id="container"> <div id="fd"></div> <div id="td"></div> <div id="sd"></div> <div>hello world is my</div> <div>fist class</div> </div> </body> </html>
#fd{
width: 200px;
height: 350px;
background-color: red;
float: left;
}
#td{
width: 150px;
height: 100px;
background-color: #68ff59;
}
#sd{
width: 100px;
height: 100px;
background-color: #3953ff;
float: left;
}
#container{
width: 400px;
height: 400px;
background-color: silver;
}绿色块没有设置浮动,被红色块覆盖了,但是文字“hello world is my”“fist class”也没有设置浮动,怎么会有浮动效果而没有被覆盖呢
三咚
躺平的momo
echo_kinchao
随时随地看视频慕课网APP