topnush
Take this simple MWE:
```
\documentclass[a4paper,10pt]{article}
%opening
\title{Guide for 2017/8}
\author{Author}
\begin{document}
\date{}
\maketitle
\section{Guide}
\end{document}
```
Is it possible to have 2017/18 automatically set to the current year? So in this case it should be 2021/22.
Top Answer
samcarter
Without additional packages, the following should do until the end of the century:
```
\documentclass[a4paper,10pt]{article}
\newcounter{nextyear}
\setcounter{nextyear}{\year}
\addtocounter{nextyear}{1}
\addtocounter{nextyear}{-2000}
%opening
\title{Guide for \the\year/\thenextyear}
\author{Author}
\begin{document}
\date{}
\maketitle
\section{Guide}
\end{document}
```
Or a general solution with the `datetime2` package:
```
\documentclass[a4paper,10pt]{article}
\usepackage{datetime2}
\DTMsavenow{now}
%opening
\title{Guide for \DTMfetchyear{now}/\DTMtwodigits{\numexpr\DTMfetchyear{now}+1\relax}}
\author{Author}
\begin{document}
\date{}
\maketitle
\section{Guide}
\end{document}
```
![Screenshot 2021-12-02 at 13.45.11.png](/image?hash=d8bb1b46de157d3b87d66776d95cfcc62706a5512d8b6e4e134b6040eca6ce92)