latex伪代码一些记录

参考一

参考二

参考三

使用minipage

最终调整好的效果:

$
\begin{document}
\begin{center}
\begin{minipage}{15.92cm}
\renewcommand{\thealgorithm}{1}
\begin{CJK}{GBK}{song}
\begin{algorithm}[H]
	\caption{ \text{算法1:xxx}}
	\begin{algorithmic}[1]
	\Require
		\text{输入}
	\Ensure
		\text{输出}
	\end{algorithmic}
\end{algorithm}
\end{CJK}
\end{minipage}
\end{center}
\end{document}

$

如下图:页面宽度不超出边距
在这里插入图片描述

中英文版本的修改

表格能够实现的例子:l(left)居左显示 r(right)居右显示 c居中显示

\begin{document}
\begin{center}
\begin{CJK}{GBK}{song}
\begin{tabular}{@{}llllll@{}}
\toprule  %添加表格头部粗线
\text{数据集}&\text{节点数} & \text{边数} & \text{属性数} & \text{类标数} & \text{异常}\\
\midrule  %添加表格中横线
Cora&2,708 & 5,429 & 1,433 & 7 & 150\\
Citeseer&3,327 &4,732 & 4,703 & 6 & 200 \\
Blog&5,196 &171,743 & 8,189 & 6 & 300 \\
Flickr& 7,575 & 239,738 & 12,047 & 9 & 450 \\
Pubmed&19,717 &44,338 & 500 & 3 & 600 \\
\bottomrule %添加表格底部粗线
\end{tabular}
\end{CJK}
\end{center}
\end{document}

表格参考

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值