gpt4 book ai didi

datetime - 使用包日期时间将当前时间添加到\today? ( latex )

转载 作者:行者123 更新时间:2023-12-02 16:36:10 28 4
gpt4 key购买 nike

我正在尝试让我的 LaTeX 文章打印时包含当前日期和时间。我找到了一个名为 datetime 的包,它可以让我将 \today 重新定义为各种格式。但它没有一个明显的方法来修改 \today 以包含时间,而且代码是如此扭曲,我自己无法弄清楚。有没有简单的方法可以做到这一点?

编辑

当我运行 \maketitle 命令时,我希望在首页上自动打印时间和日期。默认情况下,它在隐藏命令 \date{\today} 中执行。

最佳答案

别介意我的评论,我发现了一些无需所有 makeatletters 即可工作的东西

\usepackage{datetime}
%...
\title{This is the Title}
\author{An Author's name}
\date{\currenttime}
\maketitle

关于datetime - 使用包日期时间将当前时间添加到\today? ( latex ),我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/4064408/

28 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com