Given the type hierarchy defined below, Choose the most correct statement below?
trait A{ def a = 1 } trait X extends A{ override def a = { println("X") super.a } } trait Y extends A{ override def a = { println("Y") super.a } } For the expression val xy = new AnyRef with X with Y
Correct Answer: The expression “with X with Y” is an example of the mixin syntax
Explanation:
Note: This Question is unanswered, help us to find answer for this one
More Scala MCQ Questions