# ee.List

<br />

Constructs a new list.

<br />

| Usage | Returns |
|---|---|
| `ee.List(list)` | List |

| Argument | Type | Details |
|---|---|---|
| `list` | List\[Object\]\|Object | A list or a computed object. |

## Examples

### Code Editor (JavaScript)

```javascript
print(ee.List([]));  // []
print(ee.List([null]));  // [null]
print(ee.List([true]));  // [true]
print(ee.List([1]));  // [1]
print(ee.List([ee.Number(1)]));  // [1]
print(ee.List(['a']));  // ["a"]
print(ee.List([[]]));  // [[]]
print(ee.List([ee.List([])]));  // [[]]
print(ee.List([[], [[]], [1, [], 'a']]));  // [[],[[]],[1,[],"a"]]
```
Python setup

See the [Python Environment](https://developers.google.com/earth-engine/guides/python_install) page for information on the Python API and using
`geemap` for interactive development.

```python
import ee
import geemap.core as geemap
```

### Colab (Python)

```python
display(ee.List([]))  # []
display(ee.List([None]))  # [None]
display(ee.List([True]))  # [True]
display(ee.List([1]))  # [1]
display(ee.List([ee.Number(1)]))  # [1]
display(ee.List(['a']))  # ['a']
display(ee.List([[]]))  # [[]]
display(ee.List([ee.List([])]))  # [[]]
display(ee.List([[], [[]], [1, [], 'a']]))  # [[], [[]], [1, [], 'a']]
```