Skip to content

Commit 4b07770

Browse files
committed
correct tab in scala-features.md
1 parent b884738 commit 4b07770

File tree

1 file changed

+0
-12
lines changed

1 file changed

+0
-12
lines changed

_zh-cn/overviews/scala3-book/scala-features.md

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -113,18 +113,6 @@ That is, we don’t write imperative code like this:
113113
正如函数式编程的说法,在 Scala 中,您编写您想要 _“什么”_,而不是 _“如何”_ 去实现它。
114114
也就是说,我们不会像这样编写命令式代码:
115115

116-
{% tabs scala-features-1 class=tabs-scala-version %}
117-
{% tab 'Scala 2' for=scala-features-1 %}
118-
```scala
119-
def double(ints: List[Int]): List[Int] = {
120-
val buffer = new ListBuffer[Int]()
121-
for (i <- ints) {
122-
buffer += i * 2
123-
}
124-
buffer.toList
125-
}
126-
127-
val newNumbers = double(oldNumbers)
128116
{% tabs scala-features-1 class=tabs-scala-version %}
129117
{% tab 'Scala 2' for=scala-features-1 %}
130118
```scala

0 commit comments

Comments
 (0)