1 2 3 4 5 6 7 8 9 10 11
import java.io.StringReader import scala.io.StdIn.readLine object Test extends dotty.runtime.LegacyApp { Console.withIn(new StringReader("")) { readLine() readLine("prompt\n") readLine("%s prompt\n", "fancy") readLine("%s %s prompt\n", "immensely", "fancy") } }