For the code below, Choose the correct statement which shows the output?
var l1 = scala.collection.mutable.MutableList[String]() val l2 = List[String]() for (a <- 1 to 100) { l1 += a.toString } println(l1 .size); for (a <- 1 to 100) { l2 :+ a.toString } println(l2 .size);
Correct Answer: 100 then 0
Explanation:
Note: This Question is unanswered, help us to find answer for this one
More Scala MCQ Questions