伪代码 - 示例


来源于:jade

伪代码: 一般用来模拟真实代码的一种简写方式

 

伪代码:

 1 !!! 5  2 html(lang="en")  3  head  4  title= pageTitle  5  :javascript  6  | if (foo) {  7  | bar()  8  | }  9  body 10  h1 Jade - node template engine 11  #container 12  - if (youAreUsingJade) 13  You are amazing 14  - else 15  Get on it! 16  Get on it! 17  Get on it! 18          Get on it!

 

真实代码:

<!DOCTYPE html>
<html lang="en">
  <head>
    <title>Jade</title>
    <script type="text/javascript">
      //<![CDATA[
      if (foo) {
          bar()
      }
      //]]>
    </script>
  </head>
  <body>
    <h1>Jade - node template engine</h1>
    <div id="container">
      <p>You are amazing</p>
    </div>
  </body>
</html>    

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM