diff --git a/docs/11/a.md b/docs/11/a.md index 047c378..f379c13 100644 --- a/docs/11/a.md +++ b/docs/11/a.md @@ -33,12 +33,13 @@ scala> def triangle4: Unit = { We can abstract out 4 into a parameter: ```console -scala> def triangle(side: Int): Unit = { - (1 to side) foreach { row => - (1 to row) foreach { col => - println("*") - } - } +scala> def triangle2(side: Int): Unit = { + (1 to side) foreach { row => + (1 to row) foreach { col => + print("*") + } + print("\n") + } } ```