changed value in BaseNValue to be a lazy val
Implemented and tested nextDigit method in BaseNValue