se percent signs follow numbers.
The expression ${DIRSTACK :-$PWD} evaluates to $DIRSTACK if it is non-null or $PWD (the current directory) if it is null.
Table 4.1: Substitution Operator... ss rather than within the shell. Another utility, dirname(1), does essentially the opposite of basename