![如何用逗号代替连字符来放置连续的引用?](https://linux22.com/image/470445/%E5%A6%82%E4%BD%95%E7%94%A8%E9%80%97%E5%8F%B7%E4%BB%A3%E6%9B%BF%E8%BF%9E%E5%AD%97%E7%AC%A6%E6%9D%A5%E6%94%BE%E7%BD%AE%E8%BF%9E%E7%BB%AD%E7%9A%84%E5%BC%95%E7%94%A8%EF%BC%9F.png)
我的报告中有很多引用,我使用了\cite{author1, author2, author3, author4, author5}
。这个的输出是[1-5]
。但我想要一些像 这样的明确的东西[1,2,3,4,5]
。有什么办法吗?
答案1
cite
只需使用该选项加载包即可nocompress
。
\documentclass{article}
\begin{filecontents}[overwrite]{mybib.bib}
@misc{a, author="Anne Author", title="Thoughts", year=3001}
@misc{b, author="Brenda Brown", title="Thoughts", year=3002}
@misc{c, author="Carla Case", title="Thoughts", year=3003}
@misc{d, author="Daniela Dixit", title="Thoughts", year=3004}
@misc{e, author="Erica Easterlin",title="Thoughts", year=3005}
\end{filecontents}
\usepackage[nocompress]{cite}
\bibliographystyle{plain} % or some other suitable bib style
\begin{document}
\cite{a,b,c,d,e}
\bibliography{mybib}
\end{document}