Lecture overview -- Keyboard shortcut: 'u'  Previous page: Classical higher-order functions: Overview -- Keyboard shortcut: 'p'  Next page: The mapping function -- Keyboard shortcut: 'n'  Lecture notes - all slides and notes together  slide -- Keyboard shortcut: 't'  Help page about these notes  Alphabetic index  Course home  Lecture 2 - Page 20 : 35
Programming Paradigms
Recursion and Higher-order Functions
Mapping

The idea of mapping is to apply a function on each element of a list, hereby collecting the list of the function applications

A mapping function m applies a function on each element of a list (e1, e2, ... en)

The mapping functions returns the list of these applications

Mapping a function m on a list. m is applied on every element, and the list of these applications is returned.

 

The function map is an essential Scheme function