# ArrayEx.SortMapWithNulls<T> examples

Examples for [SortMapWithNulls<T>](https://developer.rhino3d.com/api/gh2/type/grasshopper2.extensions.arrayex/sortmapwithnulls.md) in Grasshopper2.Extensions.ArrayEx.

## C#

```cs
using Grasshopper2.Extensions;

// As an extension method
Maths.IndexMap result = array.SortMapWithNulls(nullMap, comparer);

// As a static method
result = ArrayEx.SortMapWithNulls(array, nullMap, comparer);
```

## Python

```python
import clr
clr.AddReference('Grasshopper2')
import Grasshopper2.Extensions
clr.ImportExtensions(Grasshopper2.Extensions)

# As an extension method
result = array.SortMapWithNulls(null_map, comparer)

# As a static method
result = Grasshopper2.Extensions.ArrayEx.SortMapWithNulls(array, null_map, comparer)
```
