To create a new project with Scala 3

1sbt new scala/scala3.g8

and give it a name when asked

1$ name [Scala 3 Project Template]: <name>

Then

1cd <name>

 

Then with Visual Studio Code, open the new folder, with the name you gave. Run sbt in terminal there and run tasks there, including console for REPL

Visual Studio Code Extensions used -

  • Scala Syntax
    by scala-lang

  • Scala (sbt)
    by Lightbend


Note regarding private[this], which is not mentioned in book currently - private[this] is now dropped but inferred from private
https://dotty.epfl.ch/docs/reference/dropped-features/this-qualifier.html