# Can length function be used for function argument pattern matching

**URL:** <https://forum.elixirforum.com/t/can-length-function-be-used-for-function-argument-pattern-matching/32419>\
**Category:** Questions\
**Tags:** pattern-matching, list, length\
**Created:** [June 17, 2020, 4:43pm UTC](https://forum.elixirforum.com/t/can-length-function-be-used-for-function-argument-pattern-matching/32419 "2020-06-17T16:43:22Z")\
**Posts on this page:** 1\
**Showing post:** 10

<div class="post-metadata">

**Author:** ![dimitarvp](https://forum.elixirforum.com/user_avatar/forum.elixirforum.com/dimitarvp/32/38664_2.png) [@dimitarvp](https://forum.elixirforum.com/u/dimitarvp)\
**Post date:** [June 17, 2020, 10:50pm UTC](https://forum.elixirforum.com/t/can-length-function-be-used-for-function-argument-pattern-matching/32419/10 "2020-06-17T22:50:39Z")

</div>

I still don’t get what kind of polymorphism you are after. If you explain your intended use-case with a more complete code sample then I’m sure we can give you a proper advice.

Outside of that I am with @wolf4earth – don’t mix guards with pattern matching, they serve different purposes. You can use both at the same time though and that’s perfectly valid if you want stricter checks.

---

_[View the full topic](https://forum.elixirforum.com/t/can-length-function-be-used-for-function-argument-pattern-matching/32419)._
