$\text{FILTER-P}( {\color{gray}{\big(}} 1, 1, 2, 3, 4, 4, 5 {\color{gray}{\big)}} )$
$= \text{FILTER-P}( {\color{gray}{\big(}} 1, 2, 3, 4, 4, 5 {\color{gray}{\big)}} )$
$= \text{FILTER-P}( {\color{gray}{\big(}} 2, 3, 4, 4, 5 {\color{gray}{\big)}} )$
$= 2 :: \text{FILTER-P}( {\color{gray}{\big(}} 3, 4, 4, 5 {\color{gray}{\big)}} )$
$= 2 :: \text{FILTER-P}( {\color{gray}{\big(}} 4, 4, 5 {\color{gray}{\big)}} )$
$= 2 :: 4 :: \text{FILTER-P}( {\color{gray}{\big(}} 4, 5 {\color{gray}{\big)}} )$
$= 2 :: 4 :: 4 :: \text{FILTER-P}( {\color{gray}{\big(}} 5 {\color{gray}{\big)}} )$
$= 2 :: 4 :: 4 :: \text{FILTER-P}( {\color{gray}{\big(}} {\color{gray}{\big)}} )$
$= 2 :: 4 :: 4 :: {\color{gray}{\big(}} {\color{gray}{\big)}}$
$= 2 :: 4 :: {{\color{gray}{\big(}}} 4 {\color{gray}{\big)}}$
$= 2 :: {\color{gray}{\big(}} 4, 4 {\color{gray}{\big)}}$
$= {\color{gray}{\big(}} 2, 4, 4 {\color{gray}{\big)}}$
Denne funksjonen filtrerer vekk tallene som ikke er partall fra en liste. En tilsvarende funksjon i programmeringsspråket Scheme kan defineres slik (ikke pensum):
(define (filter-even items)
(cond ((null? items) '())
((even?(car items))
(cons (car items) (filter-even (cdr items))))
(else (filter-even (cdr items)))))