Explain the difference between a trait and an abstract class?
Answer / Rohit Agrawal
{"Traits": ["Traits in Scala are like interfaces + multiple inheritance. They can contain methods, variables, and other traits. A class adopting a trait inherits all members of that trait."], "Abstract Classes": ["An abstract class is a partially implemented class that cannot be instantiated directly. It contains both concrete (implemented) and abstract (unimplemented) methods. Unlike interfaces, it can contain variables as well."]}
| Is This Answer Correct ? | 0 Yes | 0 No |
Explain if-else-if terminology?
What do you understand by tail recursion in scala ?
Does Scala support all Functional Programming concepts? Does Java 8 support all Functional Programming concepts?
mention the types of variables in scala? And what is the difference between them?
Why Scala does NOT have 'static' keyword? What is the main reason for this decision?
What is the equivalent construct of Scala’s Option in Java SE 8? What is the use of Option in Scala?
Explain the main difference between List and Stream in Scala Collection API? How do we prove that difference? When do we choose Stream?
How is a class different from an object?
Differentiate between array and list in scala.
What is seq in scala collection?
What is scala closure?
What is an array in scala?