I see the following example on chapter 5 in FP in scala to drive home non-strictness
val x = Cons(() => expensive(x), tl)
val h1 = x.headOption
val h2 = x.headOption
and I am trying to understand how
val x = Cons(() => expensive(x), tl) works? specifically the thunk () => expensive(x), given x itself is being defined?