在画这个的时候,class为right的div的float设置为right或者left都没有影响,是为什么呢

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Document</title>
<style>
.root {
width: 500px;
height: 500px;
}
.right {
height: 500px;
width: 250px;
background-color: burlywood;
float: right;
/* float: left; */
}
.left {
height: 500px;
width: 250px;
float: left;
}
.top {
height: 250px;
width: 250px;
background-color: pink;
}
.bottom {
height: 250px;
width: 250px;
background-color: turquoise;
}
</style>
</head>
<body>
<script src="test.js"></script>
练习测试页面
<div class="root">
<div class="left">
<div class="top"></div>
<div class="bottom"></div>
</div>
<div class="right"></div>
</div>
</body>
</html>