Scala Map take() method with example
The take() method is utilized to select the first 'n' elements of the map. Method Definition: def take(n: Int): Map[A, B] Return Type: It returns the first 'n' elements of the map. Example #1: Scala // Scala program of take() // method // Creating object object GfG { // Main method def main(args:Arr