---
title: "Discussion on \"60 PicoLisp Functions You Should Know - 6: Lists and Strings\" | Hashnode"
description: "Discussion on \"60 PicoLisp Functions You Should Know - 6: Lists and Strings\". Welcome back! This is the last post of the 60 most common PicoLisp functions series. Today we will cover lists and strings.\nWe will handle the topic lists quite extensively as it is one of the most important data types in PicoLisp. After that, we wil..."
url: "https://hashnode.com/posts/60-picolisp-functions-you-should-know-6-lists-and-strings/613b375cd6057d516e7ece96"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [60 PicoLisp Functions You Should Know - 6: Lists and Strings](https://picolisp-explored.com/60-picolisp-functions-you-should-know-6-lists-and-strings?utm_source=hashnode&utm_medium=feed)

Welcome back! This is the last post of the 60 most common PicoLisp functions series. Today we will cover lists and strings. We will handle the topic lists quite extensively as it is one of the most important data types in PicoLisp. After that, we wil...

Sep 10, 2021 · 7 min read · picolisp-explored.com  
Updated Sep 25, 2021  
Read the article

-   [#functional-programming](https://hashnode.com/tag/functional-programming)
-   [#data-structures](https://hashnode.com/tag/data-structures)
-   [#string](https://hashnode.com/tag/string)
-   [#functions](https://hashnode.com/tag/functions)
-   [#basics](https://hashnode.com/tag/basics)

## Written by

[Mia Temma](https://hashnode.com/@miatemma)

@miatemma · Berlin, Germany

  
[View profile](https://hashnode.com/@miatemma)

## Responses 1

Markdown supported · ⌘↵ to post

[Olaf](https://hashnode.com/@olaf)

[Sep 11, 2021](https://hashnode.com/posts/60-picolisp-functions-you-should-know-6-lists-and-strings/613b375cd6057d516e7ece96/comment/613c62f51821961e2551e18b)

Hi Mia, I do like the list part of this article, I never used yoke before (even did'nt know about it), now I will :-)

The 'c\[a|d\]+r' :-) functions in picolisp exist as a tribute for old lisper's, are'nt they? For beginners to (pico)Lisp I would prefer to define

```
(setq first        car)    # you can call it first-of-list  if you want
(setq rest-of-list cdr)   # rest would overwrite existing picolisp core function
```

For me it was easier to understand and to remember

```
: (first (rest-of-list '(1 2 3 4 5 6))    # same as (cadr '(1 2 3 4 5 6))
-> 2

: (rest-of-list (first '((1 2) 3 4 5 6))    # same as (cdar '((1 2) 3 4 5 6))
-> (2)
```

But for sure, `(first (rest-of-list (rest-of-list (rest-of-list '(1 2 3 4 5 6))))` would never ever be used (and therefore never be listed under the 60 most used functions) instead of a simple `(cadddr (1 2 3 4 5 6))`  
:-)

(By the way, both should return: 4)

[Mia Temma](https://hashnode.com/@miatemma)

[Sep 11, 2021](https://hashnode.com/posts/60-picolisp-functions-you-should-know-6-lists-and-strings/613b375cd6057d516e7ece96/comment/613c62f51821961e2551e18b#reply-613c67ef1821961e2551e25c)

Thank you! The function redefinition is a really good idea!
