# Example - Discussion

**URL:** https://swi-prolog.discourse.group/c/example/discussion/29.md

[Latest](https://swi-prolog.discourse.group/latest.md) · [Categories](https://swi-prolog.discourse.group/categories.md) · [Tags](https://swi-prolog.discourse.group/tags.md)

---

## [About the Example - Discussion category](https://swi-prolog.discourse.group/t/about-the-example-discussion-category/3371)

<div class="topic-metadata">

**Author:** [@EricGT](https://swi-prolog.discourse.group/u/EricGT)\
**Replies:** 0

</div>

This category was created to hold the discussion topics related to examples for RFC: Towards an infrastructure for examples. The idea is to create the example in the Example category and create a separate related discu…

---

## [Example Discussion - Predicate: group\_by/4](https://swi-prolog.discourse.group/t/example-discussion-predicate-group-by-4/3374)

<div class="topic-metadata">

**Author:** [@EricGT](https://swi-prolog.discourse.group/u/EricGT)\
**Replies:** 3\
**Last updated:** [December 15, 2020, 12:56pm UTC](https://swi-prolog.discourse.group/t/example-discussion-predicate-group-by-4/3374 "2020-12-15T12:56:00Z")

</div>

This is just a sample topic to demonstrate an example discussion for the related group\_by/4 example. The topic Predicate: group\_by/4 holds the examples and this topic is to discuss the examples. The code for the exampl…

---

## [Using maplist with many arguments: Example](https://swi-prolog.discourse.group/t/using-maplist-with-many-arguments-example/3369)

<div class="topic-metadata">

**Author:** [@Boris](https://swi-prolog.discourse.group/u/Boris)\
**Replies:** 2\
**Last updated:** [December 15, 2020, 9:09am UTC](https://swi-prolog.discourse.group/t/using-maplist-with-many-arguments-example/3369 "2020-12-15T09:09:28Z")

</div>

The current maplist implementation allows up to 4 lists. Here is what happens if you happen to have a predicate with more than 4 arguments: $ cat maplistexample.pl sum\_products(A, B, C, D, R) :- R is A+B \* C+D. sum…
