# Supporting syntax \`x not in y\` as alias for \`!(x in y)\`

**URL:** https://discourse.julialang.org/t/supporting-syntax-x-not-in-y-as-alias-for-x-in-y/110146
**Category:** Internals & Design
**Created:** [February 13, 2024, 11:01am UTC](https://discourse.julialang.org/t/supporting-syntax-x-not-in-y-as-alias-for-x-in-y/110146 "2024-02-13T11:01:34Z")
**Posts on this page:** 1
**Showing post:** 6

<div class="post-metadata">

### Author: ![fingolfin](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/fingolfin/32/6033_2.png) [@fingolfin](https://discourse.julialang.org/u/fingolfin)
#### Post date: [February 13, 2024, 2:41pm UTC](https://discourse.julialang.org/t/supporting-syntax-x-not-in-y-as-alias-for-x-in-y/110146/6 "2024-02-13T14:41:54Z")

</div>

Thanks for the pointers to the two existing issues. Though I’d consider `!in` strictly inferior to `not in` in terms of readability.

Also thanks to pointing out ∉ – I’ll make sure to use that for demos but I don’t feel comfortable using unicode like that in my actual code (of course that’s a “me” problem 😉 ).

> [@HanD](#):
>
> My personal convention is to use ∈, ∋, and ∉ for inclusion tests, and `in` for iteration (which is a syntactic sugar for = anyhow).

Totally off-topic, but: for iteration, I don’t view `in` as syntactic sugar for `=`, but rather `=` as a horrible alternative syntax for `in` that is there to appease people coming from certain programming languages – it is IMHO utterly confusing for anyone else :-).

---

_[View the full topic](https://discourse.julialang.org/t/supporting-syntax-x-not-in-y-as-alias-for-x-in-y/110146)._
