# List Nodes

This sub-section provides helper functions related to lists.

![](/files/O2IulzcOPhf7hu4ltDcu)

### List | First Item

![](/files/igmuNF3ZM5rSDjnXPr1o)

This node returns the first element of the provided list \[the first element is the element which is stored at 0 index in list].

For example – list = \[1,2,3,4,5] then this node return result = 1.

### List | Last Item

![](/files/Dwnfuv19PoccZel6BHfm)

This node returns the last element of the provided list.

For example, list = \[1,2,3,4,5] then this node return result = 5.

### List | Reverse

![](/files/Sn8yooPxh4XqiZ4SJqvs)

This node reverses the provided list.

For example, list = \[1,2,3,4,5] , node result = \[5,4,3,2,1].

### List | Remove At

![](/files/kzXaoRQ2gqBR305r6FCN)

This node removes the element at the provided index from the list.

The provided index should be between 0 <= index < list Length.

For example, list = \[1,2,3,4,5], index = 1 result list = \[1,3,4,5];

{% hint style="info" %} <mark style="color:blue;">Note: Indexing in list starts from zero.</mark>
{% endhint %}

### List | Remove Value

![](/files/gYJEkQ8cYmrpg30uN1Go)

This node removes the first occurrence of the given value from the list.

For example, list = \[1,2,3,4,5,1], and value = 1, so this node will return: \[2,3,4,5,1].

### List | Add Value

![](/files/z6qSvAxyYqkPt94apEon)

This node adds a value to the end of the list, extending the length by one.

For example, list = \[1,2,3,4,5] and value = 6, so the node return = \[1,2,3,4,5,6].

### List | Add List

![](/files/xO1LLd1rDRyR0eThO3ie)

This node combines two lists into a single list. The length of the resultant list is the sum of the length of the first and second lists.

For example, Input list1 = \[1,2,3] and Input list2 = \[4,5,6] and the Output list: \[1,2,3,4,5,6].

### List | Insert At

![](/files/DjbX2cq2dTrINUk9y6xL)

This node helps you to insert at a particular position or index in the list, inserting an item into the list can cause the increase in the length of the list by one and shifts all objects at or after the index towards the end of the list.

For example, Input list: \[1, 2, 3, 4], index: 2, element: 10 Output list: \[1, 2, 10, 3, 4].

### List | Remove Range

![](/files/ZdJKpqixgMrCa9md9rNA)

This node helps you to remove multiple sets of consecutive elements from the list at once.

Removes the elements with positions greater than or equal to start and less than the end, from the list. This reduces the list's length by the end - start.

For example, Input list = \[1,2,3,4,5,6] , start index: 0, end index: 2 and the Output list: \[3,4,5,6] because end is not included.

### List | Clear

![](/files/h7CseogZbBPMPZjlxzPg)

This node helps you to Removes all objects from this list; the length of the list becomes zero.

This node returns the empty list which can be used again for adding items or elements.

For example Input list: \[1,2,3,4,5], Output list: \[].

### List | Length

![](/files/fLd5PF9duK9TOPL90ftq)

This node calculates the length of the list, indicating how many elements are present.

For example, Input list: \[1,2,3,4,5], Output length: 5 total 5 elements are present.

### List | Is Empty

![](/files/41Crj3Qi3CwQvESEZyLD)

This node helps you to check whether the provided list is empty or not, if the provided list is empty then the node returns True else it returns false.

For example, Input list: \[1,2,3,4], Output: false, if Input list: \[], Output: true.

### List | Index Of

![](/files/nYyH2C299GM53hQ4FozT)

This node finds the index of a particular element in the list. It returns the index of the first occurrence of the element.

For example, Input list: \[1,2,3,4], element: 3, then node Output index: 2.

{% hint style="info" %} <mark style="color:blue;">Note: The index in the list starts from zero.</mark>
{% endhint %}

### List | Element At

![](/files/Oi7vVG3uEAj58Toe50IP)

This node helps you to get the element at a particular index. This node returns the value of the item or element present at the given index.

For example, list = \[1,2,3,4,5,6] , index =2, then the node return 3, as indexing in list starts from zero.

If you have any ideas to make Blup better you can share them through our [Discord community channel](https://discord.com/channels/940632966093234176/965313562425823303)

## Music to go with.

{% embed url="<https://open.spotify.com/playlist/0vvXsWCC9xrXsKd4FyS8kM?si=2c7f55bd3f944878>" %}
Lofi music
{% endembed %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.blup.in/wiki/logics/helper-nodes/list-nodes.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
