• Markdown的基本语法记录


    1.标题

    示例代码:

    # 标题1
    ## 标题2
    ### 标题3
    #### 标题4
    ##### 。。。
    

    效果:

    标题1

    标题2

    标题3

    标题4

    。。。

    注:# 后面应保持空格

    2. 分级标题

    示例代码:

    一级标题
    ===================
    二级标题
    ------------------
    

    效果:

    一级标题

    二级标题

    注: = - 最少写两个

    3.引用

    代码示例

    单行引用
    >hello,python
    
    多行引用
    >hello,python
    
    >>hello,world
    
    >>>hello,123
    
    

    效果:

    单行引用

    hello,python

    多行引用

    hello,python

    hello,world

    hello,123

    注:>可以一直加

    4.行内标记

    代码示例:

    这是`我的`一句话
    

    效果:
    这是我的一句话

    6.字体加粗

    代码示例:

    **这是一行字**
    
    

    效果:
    这是一行字

    7.字体斜体

    代码示例:

    *这是一行字*
    _这是一行字_
    
    

    效果:
    这是一行字
    这是一行字

    8.粗体斜体

    代码示例:

    ***这是一行字***
    **_这是一行字_**
    
    

    效果:
    这是一行字
    这是一行字

    9.字体删除字

    代码示例:

    ~~这是一行字~~
    

    效果:
    这是一行字

    10.格式化文本

    保持输入的格式排版不变
    代码示例:

    <pre>
    aaa
    bbb
    ccc    asdha
    </pre>
    

    效果:

    aaa
    bbb
    ccc    asdha
    

    11.代码块

    代码块1
    代码示例:
    ```
    print("hello,python")
    ```

    效果:

    print("hello,python")
    

    代码块2(自定义语法)
    代码示例:
    ```python
    print("hello,python")
    ```

    ```java
    System.out.print("hello,java")
    ```

    效果:

    print("hello,python")
    
    System.out.print("hello,java")
    

    注:这里为了演示代码用到了\` 来区别代码块中的`字符,用<code></code>代替了```包含的代码块

    12.插入超链接

    代码示例:

    [百度](http://www.baidu.com)
    

    效果:
    百度

    13.插入图片

    代码示例:

    ![图片无法正常显示时显示的文本](./123.png)
    

    效果:
    图片无法正常显示时显示的文本
    注:可使用相对路径

    14.序列

    有序列表

    示例代码:

    1. one
    2. two
    3. three  
    

    效果:

    1. one
    2. two
    3. three

    无序列表

    示例代码:

    - one
    + two
    * three
    

    效果:

    • one
    • two
    • three
    序列的嵌套

    示例代码:

    1. one
       1. one
       2. one
    2. two
       + two
       + two
          - three
          - three
    

    效果:

    1. one
      1. one
      2. one
    2. two
      • two
      • two
        • three
        • three

    注: 此时应在下级敲出空格

    15.表格

    示例代码:

    幺|幺|零
    -:|:-:|:-
    你|我|它
    一个个|二个个|三个个
    四个个|五个个|六个个
    

    效果:

    一个个 二个个 三个个
    四个个 五个个 六个个

    注: 第二行表示分割出表头和内容,其中-至少打出一个,:在左边表示左对齐,在右边表示右对齐,两个:表示居中对齐

  • 相关阅读:
    N 种仅仅使用 HTML/CSS 实现各类进度条的方式
    使用 CSS 轻松实现一些高频出现的奇形怪状按钮
    通过jdb命令连接远程调试的方法
    (转)Python中asyncio与aiohttp入门教程
    (转)从0到1,Python异步编程的演进之路
    (转)python︱用asyncio、aiohttp实现异步及相关案例
    (转)Python 如何仅用5000 行代码,实现强大的 logging 模块?
    (转)python的dict()字典数据类型的方法详解以及案例使用
    (转)Python Async/Await入门指南
    (转)Python运维自动化psutil 模块详解(超级详细)
  • 原文地址:https://www.cnblogs.com/During/p/10742444.html
Copyright © 2020-2023  润新知