题解 | #盒模型- 外边距折叠#

盒模型- 外边距折叠

https://www.nowcoder.com/practice/9c6f4a2626d34b798f20ed31ba17e441

{"css":"","js":"","html":"<!DOCTYPE html>\n<html>\n    <head>\n        <meta charset=utf-8>\n        <style type=\"text/css\">\n            * {\n                margin: 0;\n                padding: 0;\n            }\n            .top {\n                \n                width:100px;\n                height:100px;\n                margin:10px;\n                background:red;\n            }\n            .bottom {\n               \n                width:100px;\n                height:100px;\n                margin:10px; \n                background-color:black;\n                position:absolute;\n            }\n        </style>\n    </head>\n    <body>\n        <section class=\"top\"></section>\n        <section class=\"bottom\"></section>\n    </body>\n</html>","libs":["jquery","underscore"]}

section是块级元素

全部评论

相关推荐

点赞 评论 收藏
分享
评论
点赞
收藏
分享

创作者周榜

更多
牛客网
牛客网在线编程
牛客网题解
牛客企业服务