创建箭头

创建箭头

我在 Latex 上显示一个输出时遇到了麻烦。是否可以使用一些 overleaf 代码来制作以下图片? 在此处输入图片描述

答案1

这个怎么样?我不确定您是否想以某种方式对齐间隔。以下解决方案需要 -package amsmath

\begin{tabular}{ll}
   1. & [0, 0.30]  \\
   2. & [0.3, 0.6] \\
   3. & [0.6, 1]
\end{tabular}
$\xrightarrow{\text{Some text here}}$
\begin{tabular}{ll}
   1. & [0,7]  \\
   2. & [7,12] \\
   3. & [12,30]
\end{tabular}

在此处输入图片描述


编辑:在评论中讨论对齐之后,尝试以下操作:

\begin{tabular}{ll@{\ }r} % <----- here you can play around with your tabular.
                          % The '@{\ }' says we want to have a normal space between the first and the second element. You could try @{\,} or @{} instead
                          % The last 'r' specifies the alignment of the last column. Maybe you want to have 'l' here.
   1. & [0,   & 0.30] \\
   2. & [0.3, & 0.6]  \\
   3. & [0.6, & 1]
\end{tabular}
% Same for the second tabular.

在此处输入图片描述

答案2

在此处输入图片描述

\documentclass{article}
\usepackage{amsmath}
\begin{document}

\[
\begin{array}{ll@{}r}
1. & [0,&0.30]\\
2. & [0.3,&0.6]\\
3. & [0.6,&1]
\end{array}
\xrightarrow{\text{some text here}}
\begin{array}{ll@{}r}
1. & [0,&7]\\
2. & [7,&12]\\
3. & [12,&30]
\end{array}\\
\]
\end{document}

相关内容