In Windows command-line I can print the year of the current date by doing this:

```
echo %date:~10,4%

```

result: 2016

Of course, depending on how dates are displayed in your language you need to change the `10` or `4` to get the correct sub string. But that's ok.

What I want it to print is `2015`, which is `2016 - 1`. So, how do I subtract 1 from the sub string I've just captured? There is no problem in using auxiliary variables.