Am I right understanding that
def is evaluated every time it gets accessed
lazy val is evaluated once it gets acce
def defines a method. When you call the method, the method ofcourse runs.
val defines a value (an immutable variable). The assignment expression is evaluated when the value is initialized.
lazy val defines a value with delayed initialization. It will be initialized when it's first used, so the assignment expression will be evaluated then.