2

I want to make the format of my text just as below by using markdown:

wanted format

how could i write the markdown file?

denis
  • 21,378
  • 10
  • 65
  • 88
Sim Sun
  • 587
  • 1
  • 4
  • 28
  • 1
    Markdown is intended to produce HTML, not a specific presentation. Therefore it would be helpful to know what is the desired outcome in terms of HTML. – Jonas Jan 12 '12 at 17:21
  • Similar to: https://stackoverflow.com/q/6046263/1959808 – 0 _ May 30 '21 at 09:56

2 Answers2

4

As a general answer to the title of the question:

Use the "Greater-Than Sign followed by a Space (> )" will indent the line:

> This line will be indented.

This will work in not only Jupyter but also other markdowns.

E.g. The indented text shown here on the StackOverflow page is like this:

This line will be indented.

Credit from this IBM markdown cheatsheet.

Lucecpkn
  • 971
  • 6
  • 9
1
 1. 1
 1. 2
   1. 1
   1. 2
 1. 3

outputs

  1. 1
  2. 2
    1. 1
    2. 2
  3. 3

the sub-numbers 2.1. is not super easy to achieve in HTML, that's the limitation here.

greut
  • 4,305
  • 1
  • 30
  • 49
  • Just wanted to mention that this solution works just by accident. The proper way would be to do it in CSS with the `counter` function. http://www.standardista.com/css3/creating-counters-with-generated-content/ – Jonas Jan 12 '12 at 17:27
  • @Jonas linkrot: https://web.archive.org/web/20221103084209/https://www.standardista.com/css3/creating-counters-with-generated-content/ though 2012 one is a bit more expressive: https://web.archive.org/web/2012/https://www.standardista.com/css3/creating-counters-with-generated-content/ – user8395964 Jun 25 '23 at 15:41