blob: 50c83ac81924ccf33c09b552810637580d505a35 (
plain) (
blame)
1
2
3
4
5
6
7
|
object Test {
def main(args: Array[String]) {
(Stream.from(1).collect{case x if x > 5000000 => x}: Stream[Int])
assert((Stream from 1 take 10 collect { case x if x <= 3 => x*x }).sum == 14)
}
}
|