# Choosing a function at random

**URL:** <https://forum.kirupa.com/t/choosing-a-function-at-random/132434>\
**Category:** Uncategorized\
**Created:** [December 28, 2004, 5:11pm UTC](https://forum.kirupa.com/t/choosing-a-function-at-random/132434 "2004-12-28T17:11:24Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![sv85](https://avatars.discourse-cdn.com/v4/letter/s/ecd19e/32.png) [@sv85](https://forum.kirupa.com/u/sv85)\
**Post date:** [December 28, 2004, 5:11pm UTC](https://forum.kirupa.com/t/choosing-a-function-at-random/132434/1 "2004-12-28T17:11:24Z")

</div>

Hey guys/gals. Does anyone know how to choose a function at random using javascript. I have three functions and I want them to be chosen at random, what is the best way to do this?

Thanks everyone.
