Thread a function through a list, iterating on an element and the previous element.
1 |
xs |
list. The list to iterate over. |
fn |
function. A function that takes two arguments – the previous position and the current position – and returns one element back. |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.