# MutableFloatList

Artifact: [androidx.collection:collection](https://developer.android.com/jetpack/androidx/releases/collection) [View Source](https://cs.android.com/search?q=file:androidx/collection/FloatList.kt+class:androidx.collection.MutableFloatList) Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

*** ** * ** ***


```
public final class MutableFloatList extends FloatList
```

<br />

|---|---|---|
| [java.lang.Object](https://developer.android.com/reference/java/lang/Object.html) |||
| ↳ | [androidx.collection.FloatList](https://developer.android.com/reference/androidx/collection/FloatList) ||
|   | ↳ | [androidx.collection.MutableFloatList](https://developer.android.com/reference/androidx/collection/MutableFloatList) |

*** ** * ** ***

`https://developer.android.com/reference/androidx/collection/MutableFloatList` is a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-mutable-list/index.html`-like collection for `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-float/index.html` values. It allows storing and retrieving the elements without boxing. Immutable access is available through its base class `https://developer.android.com/reference/androidx/collection/FloatList`, which has a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.collections/-list/index.html`-like interface.

This implementation is not thread-safe: if multiple threads access this container concurrently, and one or more threads modify the structure of the list (insertion or removal for instance), the calling code must provide the appropriate synchronization. It is also not safe to mutate during reentrancy -- in the middle of a `https://developer.android.com/reference/androidx/collection/FloatList#forEach(kotlin.Function1)`, for example. However, concurrent reads are safe.

## Summary

| ### Public constructors |
|---|
| `https://developer.android.com/reference/androidx/collection/MutableFloatList#MutableFloatList(kotlin.Int)(int initialCapacity)` Creates a `https://developer.android.com/reference/androidx/collection/MutableFloatList` with a `https://developer.android.com/reference/androidx/collection/MutableFloatList#capacity()` of `initialCapacity`. |

| ### Public methods |
|---|---|
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Float)(float element)` Adds `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Float)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index, float element)` Adds `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)`, shifting over any elements at `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)` and after, if any. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.FloatArray)(@https://developer.android.com/reference/androidx/annotation/NonNull float[] elements)` Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.FloatArray)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` was changed or `false` if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.FloatArray)` was empty. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)` Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(androidx.collection.FloatList)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` was changed or `false` if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(androidx.collection.FloatList)` was empty. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index, @https://developer.android.com/reference/androidx/annotation/NonNull float[] elements)` Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)`, shifting over any elements at `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)` and after, if any. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)` Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)`, shifting over any elements at `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)` and after, if any. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#clear()()` Removes all elements in the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#ensureCapacity(kotlin.Int)(int capacity)` Ensures that there is enough space to store `https://developer.android.com/reference/androidx/collection/MutableFloatList#ensureCapacity(kotlin.Int)` elements in the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final int` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#getCapacity()()` Returns the total number of elements that can be held before the `https://developer.android.com/reference/androidx/collection/MutableFloatList` must grow. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(kotlin.Float)(float element)` `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(kotlin.Float)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList` |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(kotlin.FloatArray)(@https://developer.android.com/reference/androidx/annotation/NonNull float[] elements)` Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(kotlin.FloatArray)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)` Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(androidx.collection.FloatList)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(kotlin.Float)(float element)` `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(kotlin.Float)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(kotlin.FloatArray)(@https://developer.android.com/reference/androidx/annotation/NonNull float[] elements)` Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(kotlin.FloatArray)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)` Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(androidx.collection.FloatList)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#remove(kotlin.Float)(float element)` Removes `https://developer.android.com/reference/androidx/collection/MutableFloatList#remove(kotlin.Float)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAll(kotlin.FloatArray)(@https://developer.android.com/reference/androidx/annotation/NonNull float[] elements)` Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAll(kotlin.FloatArray)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if anything was removed. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAll(androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)` Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAll(androidx.collection.FloatList)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if anything was removed. |
| `final float` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAt(kotlin.Int)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index)` Removes the element at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAt(kotlin.Int)` and returns it. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int start, @https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int end)` Removes items from index `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` (inclusive) to `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` (exclusive). |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#retainAll(kotlin.FloatArray)(@https://developer.android.com/reference/androidx/annotation/NonNull float[] elements)` Keeps only `https://developer.android.com/reference/androidx/collection/MutableFloatList#retainAll(kotlin.FloatArray)` in the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and removes all other values. |
| `final boolean` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#retainAll(androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)` Keeps only `https://developer.android.com/reference/androidx/collection/MutableFloatList#retainAll(androidx.collection.FloatList)` in the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and removes all other values. |
| `final float` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index, float element)` Sets the value at `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)` to `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)`. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#sort()()` Sorts the `https://developer.android.com/reference/androidx/collection/MutableFloatList` elements in ascending order. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#sortDescending()()` Sorts the `https://developer.android.com/reference/androidx/collection/MutableFloatList` elements in descending order. |
| `final void` | `https://developer.android.com/reference/androidx/collection/MutableFloatList#trim(kotlin.Int)(int minCapacity)` Reduces the internal storage. |

### Inherited methods

From [androidx.collection.FloatList](https://developer.android.com/reference/androidx/collection/FloatList) `final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#any()()`

Returns `true` if there's at least one element in the collection.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#any(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Returns `true` if any of the elements give a `true` return value for `https://developer.android.com/reference/androidx/collection/FloatList#any(kotlin.Function1)`.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Int,kotlin.Int,kotlin.Int)(
int element,
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int fromIndex,
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int toIndex
)`

Searches this list for the specified `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Int,kotlin.Int,kotlin.Int)` in the range defined by `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Int,kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Int,kotlin.Int,kotlin.Int)`.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Int,kotlin.Int,kotlin.Function1)(
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int fromIndex,
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int toIndex,
@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Integer.html> comparison
)`

Searches this `https://developer.android.com/reference/androidx/collection/FloatList` or its range for an element for which the given `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Int,kotlin.Int,kotlin.Function1)` function returns zero using binary search algorithm.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Float,kotlin.Float,kotlin.Int,kotlin.Int)(
float element,
float tolerance,
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int fromIndex,
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int toIndex
)`

Searches this list for the specified `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Float,kotlin.Float,kotlin.Int,kotlin.Int)` in the range defined by `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Float,kotlin.Float,kotlin.Int,kotlin.Int)` and `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Float,kotlin.Float,kotlin.Int,kotlin.Int)` within the given `https://developer.android.com/reference/androidx/collection/FloatList#binarySearch(kotlin.Float,kotlin.Float,kotlin.Int,kotlin.Int)`.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#contains(kotlin.Float)(float element)`

Returns `true` if the `https://developer.android.com/reference/androidx/collection/FloatList` contains `https://developer.android.com/reference/androidx/collection/FloatList#contains(kotlin.Float)` or `false` otherwise.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#containsAll(androidx.collection.FloatList)(@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/androidx/collection/FloatList elements)`

Returns `true` if the `https://developer.android.com/reference/androidx/collection/FloatList` contains all elements in `https://developer.android.com/reference/androidx/collection/FloatList#containsAll(androidx.collection.FloatList)` or `false` if one or more are missing.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#count()()`

Returns the number of elements in this list.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#count(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Counts the number of elements matching `https://developer.android.com/reference/androidx/collection/FloatList#count(kotlin.Function1)`.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#elementAt(kotlin.Int)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index)`

Returns the element at the given `https://developer.android.com/reference/androidx/collection/FloatList#elementAt(kotlin.Int)` or throws `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` if the `https://developer.android.com/reference/androidx/collection/FloatList#elementAt(kotlin.Int)` is out of bounds of this collection.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#elementAtOrElse(kotlin.Int,kotlin.Function1)(
@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index,
@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Integer.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html> defaultValue
)`

Returns the element at the given `https://developer.android.com/reference/androidx/collection/FloatList#elementAtOrElse(kotlin.Int,kotlin.Function1)` or `https://developer.android.com/reference/androidx/collection/FloatList#elementAtOrElse(kotlin.Int,kotlin.Function1)` if `https://developer.android.com/reference/androidx/collection/FloatList#elementAtOrElse(kotlin.Int,kotlin.Function1)` is out of bounds of the collection.
`boolean` `https://developer.android.com/reference/androidx/collection/FloatList#equals(kotlin.Any)(https://developer.android.com/reference/java/lang/Object.html other)`

Returns `true` if `https://developer.android.com/reference/androidx/collection/FloatList#equals(kotlin.Any)` is a `https://developer.android.com/reference/androidx/collection/FloatList` and the contents of this and `https://developer.android.com/reference/androidx/collection/FloatList#equals(kotlin.Any)` are the same.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#first()()`

Returns the first element in the `https://developer.android.com/reference/androidx/collection/FloatList` or throws a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-no-such-element-exception/index.html` if it `https://developer.android.com/reference/androidx/collection/FloatList#isEmpty()`.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#first(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Returns the first element in the `https://developer.android.com/reference/androidx/collection/FloatList` for which `https://developer.android.com/reference/androidx/collection/FloatList#first(kotlin.Function1)` returns `true` or throws `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-no-such-element-exception/index.html` if nothing matches.
`final @https://developer.android.com/reference/androidx/annotation/NonNull R` `<R extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/FloatList#fold(kotlin.Any,kotlin.Function2)(
@https://developer.android.com/reference/androidx/annotation/NonNull R initial,
@https://developer.android.com/reference/androidx/annotation/NonNull Function2<@https://developer.android.com/reference/androidx/annotation/NonNull acc, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull R> operation
)`

Accumulates values, starting with `https://developer.android.com/reference/androidx/collection/FloatList#fold(kotlin.Any,kotlin.Function2)`, and applying `https://developer.android.com/reference/androidx/collection/FloatList#fold(kotlin.Any,kotlin.Function2)` to each element in the `https://developer.android.com/reference/androidx/collection/FloatList` in order.
`final @https://developer.android.com/reference/androidx/annotation/NonNull R` `<R extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/FloatList#foldIndexed(kotlin.Any,kotlin.Function3)(
@https://developer.android.com/reference/androidx/annotation/NonNull R initial,
@https://developer.android.com/reference/androidx/annotation/NonNull Function3<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Integer.html, @https://developer.android.com/reference/androidx/annotation/NonNull acc, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull R> operation
)`

Accumulates values, starting with `https://developer.android.com/reference/androidx/collection/FloatList#foldIndexed(kotlin.Any,kotlin.Function3)`, and applying `https://developer.android.com/reference/androidx/collection/FloatList#foldIndexed(kotlin.Any,kotlin.Function3)` to each element in the `https://developer.android.com/reference/androidx/collection/FloatList` in order.
`final @https://developer.android.com/reference/androidx/annotation/NonNull R` `<R extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/FloatList#foldRight(kotlin.Any,kotlin.Function2)(
@https://developer.android.com/reference/androidx/annotation/NonNull R initial,
@https://developer.android.com/reference/androidx/annotation/NonNull Function2<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull acc, @https://developer.android.com/reference/androidx/annotation/NonNull R> operation
)`

Accumulates values, starting with `https://developer.android.com/reference/androidx/collection/FloatList#foldRight(kotlin.Any,kotlin.Function2)`, and applying `https://developer.android.com/reference/androidx/collection/FloatList#foldRight(kotlin.Any,kotlin.Function2)` to each element in the `https://developer.android.com/reference/androidx/collection/FloatList` in reverse order.
`final @https://developer.android.com/reference/androidx/annotation/NonNull R` `<R extends https://developer.android.com/reference/java/lang/Object.html> https://developer.android.com/reference/androidx/collection/FloatList#foldRightIndexed(kotlin.Any,kotlin.Function3)(
@https://developer.android.com/reference/androidx/annotation/NonNull R initial,
@https://developer.android.com/reference/androidx/annotation/NonNull Function3<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Integer.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull acc, @https://developer.android.com/reference/androidx/annotation/NonNull R> operation
)`

Accumulates values, starting with `https://developer.android.com/reference/androidx/collection/FloatList#foldRightIndexed(kotlin.Any,kotlin.Function3)`, and applying `https://developer.android.com/reference/androidx/collection/FloatList#foldRightIndexed(kotlin.Any,kotlin.Function3)` to each element in the `https://developer.android.com/reference/androidx/collection/FloatList` in reverse order.
`final void` `https://developer.android.com/reference/androidx/collection/FloatList#forEach(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html> block)`

Calls `https://developer.android.com/reference/androidx/collection/FloatList#forEach(kotlin.Function1)` for each element in the `https://developer.android.com/reference/androidx/collection/FloatList`, in order.
`final void` `https://developer.android.com/reference/androidx/collection/FloatList#forEachIndexed(kotlin.Function2)(
@https://developer.android.com/reference/androidx/annotation/NonNull Function2<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Integer.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html> block
)`

Calls `https://developer.android.com/reference/androidx/collection/FloatList#forEachIndexed(kotlin.Function2)` for each element in the `https://developer.android.com/reference/androidx/collection/FloatList` along with its index, in order.
`final void` `https://developer.android.com/reference/androidx/collection/FloatList#forEachReversed(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html> block)`

Calls `https://developer.android.com/reference/androidx/collection/FloatList#forEachReversed(kotlin.Function1)` for each element in the `https://developer.android.com/reference/androidx/collection/FloatList` in reverse order.
`final void` `https://developer.android.com/reference/androidx/collection/FloatList#forEachReversedIndexed(kotlin.Function2)(
@https://developer.android.com/reference/androidx/annotation/NonNull Function2<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Integer.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-unit/index.html> block
)`

Calls `https://developer.android.com/reference/androidx/collection/FloatList#forEachReversedIndexed(kotlin.Function2)` for each element in the `https://developer.android.com/reference/androidx/collection/FloatList` along with its index, in reverse order.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#get(kotlin.Int)(@https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int index)`

Returns the element at the given `https://developer.android.com/reference/androidx/collection/FloatList#get(kotlin.Int)` or throws `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` if the `https://developer.android.com/reference/androidx/collection/FloatList#get(kotlin.Int)` is out of bounds of this collection.
`final @https://developer.android.com/reference/androidx/annotation/NonNull https://kotlinlang.org/api/core/kotlin-stdlib/kotlin.ranges/-int-range/index.html` `https://developer.android.com/reference/androidx/collection/FloatList#getIndices()()`

Returns an `https://developer.android.com/reference/androidx/annotation/IntRange` of the valid indices for this `https://developer.android.com/reference/androidx/collection/FloatList`.
`final @https://developer.android.com/reference/androidx/annotation/IntRange(from = -1) int` `https://developer.android.com/reference/androidx/collection/FloatList#getLastIndex()()`

Returns the last valid index in the `https://developer.android.com/reference/androidx/collection/FloatList`.
`final @https://developer.android.com/reference/androidx/annotation/IntRange(from = 0) int` `https://developer.android.com/reference/androidx/collection/FloatList#getSize()()`

The number of elements in the `https://developer.android.com/reference/androidx/collection/FloatList`.
`int` `https://developer.android.com/reference/androidx/collection/FloatList#hashCode()()`

Returns a hash code based on the contents of the `https://developer.android.com/reference/androidx/collection/FloatList`.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#indexOf(kotlin.Float)(float element)`

Returns the index of `https://developer.android.com/reference/androidx/collection/FloatList#indexOf(kotlin.Float)` in the `https://developer.android.com/reference/androidx/collection/FloatList` or `-1` if `https://developer.android.com/reference/androidx/collection/FloatList#indexOf(kotlin.Float)` is not there.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#indexOfFirst(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Returns the index if the first element in the `https://developer.android.com/reference/androidx/collection/FloatList` for which `https://developer.android.com/reference/androidx/collection/FloatList#indexOfFirst(kotlin.Function1)` returns `true`.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#indexOfLast(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Returns the index if the last element in the `https://developer.android.com/reference/androidx/collection/FloatList` for which `https://developer.android.com/reference/androidx/collection/FloatList#indexOfLast(kotlin.Function1)` returns `true`.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#isEmpty()()`

Returns `true` if the `https://developer.android.com/reference/androidx/collection/FloatList` has no elements in it or `false` otherwise.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#isNotEmpty()()`

Returns `true` if there are elements in the `https://developer.android.com/reference/androidx/collection/FloatList` or `false` if it is empty.
`final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence)(
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html separator,
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html prefix,
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html postfix,
int limit,
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html truncated
)`

Creates a String from the elements separated by `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence)` and using `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence)` before and `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence)` after, if supplied.
`final @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence,kotlin.Function1)(
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html separator,
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html prefix,
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html postfix,
int limit,
@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html truncated,
@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/CharSequence.html> transform
)`

Creates a String from the elements separated by `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence,kotlin.Function1)` and using `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence,kotlin.Function1)` before and `https://developer.android.com/reference/androidx/collection/FloatList#joinToString(kotlin.CharSequence,kotlin.CharSequence,kotlin.CharSequence,kotlin.Int,kotlin.CharSequence,kotlin.Function1)` after, if supplied.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#last()()`

Returns the last element in the `https://developer.android.com/reference/androidx/collection/FloatList` or throws a `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-no-such-element-exception/index.html` if it `https://developer.android.com/reference/androidx/collection/FloatList#isEmpty()`.
`final float` `https://developer.android.com/reference/androidx/collection/FloatList#last(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Returns the last element in the `https://developer.android.com/reference/androidx/collection/FloatList` for which `https://developer.android.com/reference/androidx/collection/FloatList#last(kotlin.Function1)` returns `true` or throws `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-no-such-element-exception/index.html` if nothing matches.
`final int` `https://developer.android.com/reference/androidx/collection/FloatList#lastIndexOf(kotlin.Float)(float element)`

Returns the index of the last element in the `https://developer.android.com/reference/androidx/collection/FloatList` that is the same as `https://developer.android.com/reference/androidx/collection/FloatList#lastIndexOf(kotlin.Float)` or `-1` if no elements match.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#none()()`

Returns `true` if the collection has no elements in it.
`final boolean` `https://developer.android.com/reference/androidx/collection/FloatList#reversedAny(kotlin.Function1)(@https://developer.android.com/reference/androidx/annotation/NonNull Function1<@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Float.html, @https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/Boolean.html> predicate)`

Returns `true` if any of the elements give a `true` return value for `https://developer.android.com/reference/androidx/collection/FloatList#reversedAny(kotlin.Function1)` while iterating in the reverse order.
`@https://developer.android.com/reference/androidx/annotation/NonNull https://developer.android.com/reference/java/lang/String.html` `https://developer.android.com/reference/androidx/collection/FloatList#toString()()`

Returns a String representation of the list, surrounded by "\[\]" and each element separated by ", ".

## Public constructors

### MutableFloatList

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public MutableFloatList(int initialCapacity)
```

Creates a `https://developer.android.com/reference/androidx/collection/MutableFloatList` with a `https://developer.android.com/reference/androidx/collection/MutableFloatList#capacity()` of `initialCapacity`.

## Public methods

### add

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean add(float element)
```

Adds `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Float)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true`.

### add

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void add(@IntRange(from = 0) int index, float element)
```

Adds `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)`, shifting over any elements at `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)` and after, if any.

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#add(kotlin.Int,kotlin.Float)` isn't between 0 and `https://developer.android.com/reference/androidx/collection/FloatList#size()`, inclusive |

### addAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean addAll(@NonNull float[] elements)
```

Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.FloatArray)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` was changed or `false` if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.FloatArray)` was empty.

### addAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean addAll(@NonNull FloatList elements)
```

Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(androidx.collection.FloatList)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` was changed or `false` if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(androidx.collection.FloatList)` was empty.

### addAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean addAll(@IntRange(from = 0) int index, @NonNull float[] elements)
```

Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)`, shifting over any elements at `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)` and after, if any.

| Returns |
|---|---|
| `boolean` | `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` was changed or `false` if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)` was empty |

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,kotlin.FloatArray)` isn't between 0 and `https://developer.android.com/reference/androidx/collection/FloatList#size()`, inclusive. |

### addAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean addAll(@IntRange(from = 0) int index, @NonNull FloatList elements)
```

Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList` at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)`, shifting over any elements at `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)` and after, if any.

| Returns |
|---|---|
| `boolean` | `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` was changed or `false` if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)` was empty |

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#addAll(kotlin.Int,androidx.collection.FloatList)` isn't between 0 and `https://developer.android.com/reference/androidx/collection/FloatList#size()`, inclusive |

### clear

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void clear()
```

Removes all elements in the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. The storage isn't released.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/collection/MutableFloatList#trim(kotlin.Int)` |   |

### ensureCapacity

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void ensureCapacity(int capacity)
```

Ensures that there is enough space to store `https://developer.android.com/reference/androidx/collection/MutableFloatList#ensureCapacity(kotlin.Int)` elements in the `https://developer.android.com/reference/androidx/collection/MutableFloatList`.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/collection/MutableFloatList#trim(kotlin.Int)` |   |

### getCapacity

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final int getCapacity()
```

Returns the total number of elements that can be held before the `https://developer.android.com/reference/androidx/collection/MutableFloatList` must grow.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/collection/MutableFloatList#ensureCapacity(kotlin.Int)` |   |

### minusAssign

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void minusAssign(float element)
```

`https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(kotlin.Float)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`

### minusAssign

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void minusAssign(@NonNull float[] elements)
```

Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(kotlin.FloatArray)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`.

### minusAssign

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void minusAssign(@NonNull FloatList elements)
```

Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#minusAssign(androidx.collection.FloatList)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`.

### plusAssign

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void plusAssign(float element)
```

`https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(kotlin.Float)` to the `https://developer.android.com/reference/androidx/collection/MutableFloatList`.

### plusAssign

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void plusAssign(@NonNull float[] elements)
```

Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(kotlin.FloatArray)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList`.

### plusAssign

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void plusAssign(@NonNull FloatList elements)
```

Adds all `https://developer.android.com/reference/androidx/collection/MutableFloatList#plusAssign(androidx.collection.FloatList)` to the end of the `https://developer.android.com/reference/androidx/collection/MutableFloatList`.

### remove

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean remove(float element)
```

Removes `https://developer.android.com/reference/androidx/collection/MutableFloatList#remove(kotlin.Float)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList`. If `https://developer.android.com/reference/androidx/collection/MutableFloatList#remove(kotlin.Float)` was in the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and was removed, `true` will be returned, or `false` will be returned if the element was not found.

### removeAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean removeAll(@NonNull float[] elements)
```

Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAll(kotlin.FloatArray)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if anything was removed.

### removeAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean removeAll(@NonNull FloatList elements)
```

Removes all `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAll(androidx.collection.FloatList)` from the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and returns `true` if anything was removed.

### removeAt

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final float removeAt(@IntRange(from = 0) int index)
```

Removes the element at the given `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAt(kotlin.Int)` and returns it.

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeAt(kotlin.Int)` isn't between 0 and `https://developer.android.com/reference/androidx/collection/FloatList#lastIndex()`, inclusive |

### removeRange

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void removeRange(@IntRange(from = 0) int start, @IntRange(from = 0) int end)
```

Removes items from index `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` (inclusive) to `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` (exclusive).

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` or `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` isn't between 0 and `https://developer.android.com/reference/androidx/collection/FloatList#size()`, inclusive |
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-illegal-argument-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` is greater than `https://developer.android.com/reference/androidx/collection/MutableFloatList#removeRange(kotlin.Int,kotlin.Int)` |

### retainAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean retainAll(@NonNull float[] elements)
```

Keeps only `https://developer.android.com/reference/androidx/collection/MutableFloatList#retainAll(kotlin.FloatArray)` in the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and removes all other values.

| Returns |
|---|---|
| `boolean` | `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` has changed. |

### retainAll

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final boolean retainAll(@NonNull FloatList elements)
```

Keeps only `https://developer.android.com/reference/androidx/collection/MutableFloatList#retainAll(androidx.collection.FloatList)` in the `https://developer.android.com/reference/androidx/collection/MutableFloatList` and removes all other values.

| Returns |
|---|---|
| `boolean` | `true` if the `https://developer.android.com/reference/androidx/collection/MutableFloatList` has changed. |

### set

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final float set(@IntRange(from = 0) int index, float element)
```

Sets the value at `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)` to `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)`.

| Returns |
|---|---|
| `float` | the previous value set at `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)` |

| Throws |
|---|---|
| `https://kotlinlang.org/api/core/kotlin-stdlib/kotlin/-index-out-of-bounds-exception/index.html` | if `https://developer.android.com/reference/androidx/collection/MutableFloatList#set(kotlin.Int,kotlin.Float)` isn't between 0 and `https://developer.android.com/reference/androidx/collection/FloatList#lastIndex()`, inclusive |

### sort

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void sort()
```

Sorts the `https://developer.android.com/reference/androidx/collection/MutableFloatList` elements in ascending order.

### sortDescending

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void sortDescending()
```

Sorts the `https://developer.android.com/reference/androidx/collection/MutableFloatList` elements in descending order.

### trim

Added in [1.4.0](https://developer.android.com/jetpack/androidx/releases/collection#1.4.0)

```
public final void trim(int minCapacity)
```

Reduces the internal storage. If `https://developer.android.com/reference/androidx/collection/MutableFloatList#capacity()` is greater than `https://developer.android.com/reference/androidx/collection/MutableFloatList#trim(kotlin.Int)` and `https://developer.android.com/reference/androidx/collection/FloatList#size()`, the internal storage is reduced to the maximum of `https://developer.android.com/reference/androidx/collection/FloatList#size()` and `https://developer.android.com/reference/androidx/collection/MutableFloatList#trim(kotlin.Int)`.

| See also |
|---|---|
| `https://developer.android.com/reference/androidx/collection/MutableFloatList#ensureCapacity(kotlin.Int)` |   |