题解 | #圣诞树#

圣诞树

https://www.nowcoder.com/practice/4924913926d94e96a70bbf2a50847852

<!DOCTYPE html>
<html>
  <head>
    <meta charset="utf-8" />
    <style type="text/css">
      .topbranch {
        float: left;
        width: 0px;
        height: 0px;
        /*
                * TODO: 上枝叶效果
                */
        border: 100px solid;
        border-color: transparent transparent green transparent;
        margin-left: 100px;
      }
      .middleBranch {
        width: 0px;
        height: 0px;
        /*
                * TODO: 中枝叶效果
                */
        border: 200px solid;
        border-color: transparent transparent green transparent;
      }
      .base {
        /*
                * TODO: 树干效果
                */
        width: 70px;
        height: 200px;
        background-color: gray;
        margin-left: 165px;
      }
    </style>
  </head>
  <body>
    <section class="topbranch"></section>
    <section class="middleBranch"></section>
    <section class="base"></section>
  </body>
</html>

全部评论

相关推荐

评论
3
1
分享

创作者周榜

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