From 92444248c25bef2a0b1cc5177d44473e21867d96 Mon Sep 17 00:00:00 2001 From: Attila Magyar Date: Sun, 20 Jun 2021 00:05:21 +0200 Subject: [PATCH] Update README.md --- README.md | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/README.md b/README.md index 883a252..f326269 100644 --- a/README.md +++ b/README.md @@ -220,15 +220,18 @@ Lists are java.util.LinkedHashMap instances and garbage collected automatically ## Collection operations ```forth -[ 1 2 3 4 ] { . } each \ iterets through the list and calls the quotation on each element +\ iterets through the list and calls the quotation on each element +[ 1 2 3 4 ] { . } each ``` ```forth -[ 1 2 3 4 ] { odd? } filter \ selects only the odd items from the list [ 1 3 ] +\ selects only the odd items from the list [ 1 3 ] +[ 1 2 3 4 ] { odd? } filter ``` ```forth -[ 1 2 3 4 ] { dup * } map \ transforms the list to a new list that contain the squares of the original items [ 1 4 9 16 ] +\ transforms the list to a new list that contain the squares of the original items [ 1 4 9 16 ] +[ 1 2 3 4 ] { dup * } map ``` ```forth