Home »
MCQs »
Scala MCQs
Method used to check if a list is empty in Scala –
100. Method used to check if a list is empty in Scala -
- list.isEmpty
- list.isNull
- list.empty
- None of these
Answer: a) list.isEmpty
Explanation:
Scala method list.isEmpty is used to check if a list is empty.