Timtowdi, this makes sure it's an integer, but you still need sprintf to get the leading zero:
printf '%02d', $year %= 100;
After Compline,
Zaxo
In reply to Re: sprintf the last 2 digits
by Zaxo
in thread sprintf the last 2 digits
by fireartist
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |