# How to find an instance in an array of enums?

**URL:** <https://forums.swift.org/t/how-to-find-an-instance-in-an-array-of-enums/28311>\
**Category:** Using Swift\
**Tags:** enums\
**Created:** [August 28, 2019, 10:18am UTC](https://forums.swift.org/t/how-to-find-an-instance-in-an-array-of-enums/28311 "2019-08-28T10:18:22Z")\
**Posts on this page:** 1\
**Showing post:** 5

<div class="post-metadata">

**Author:** ![jawbroken](https://avatars.discourse-cdn.com/v4/letter/j/cc9497/32.png) [@jawbroken](https://forums.swift.org/u/jawbroken)\
**Post date:** [August 28, 2019, 11:36am UTC](https://forums.swift.org/t/how-to-find-an-instance-in-an-array-of-enums/28311/5 "2019-08-28T11:36:49Z")

</div>

That idea is being discussed in [this thread](https://forums.swift.org/t/discriminatedunion-protocol/28094), and the examples there show how you can manually define your own nested enum without associated values to simplify this kind of thing.

---

_[View the full topic](https://forums.swift.org/t/how-to-find-an-instance-in-an-array-of-enums/28311)._
