How to generate only random even or odd numbers in Excel?
In this tutorial, I will introduce some formulas to help you generate only random even numbers or only random odd numbers in Excel.
Randomize integers, dates, times, strings or custom list in Excel
Randomize only even numbers
Here is a formula in Excel can only randomize even numbers.
Select a blank cell, and type this formula =EVEN(RANDBETWEEN(X,Y)) (X and Y indicate any integer numbers, and X<Y), for instance, I want to randomize even numbers between -5 and 10, now I type =EVEN(RANDBETWEEN(-5,10)) into an empty cell, press Enter key, if you need, you can drag the fill handle to a range with this formula.
Randomize only odd numbers
To only randomize odd numbers in Excel, you can do as this:
Select a cell and use this formula =ODD(RANDBETWEEN(X,Y)) (X and Y indicates any integer numbers, and X<Y), for instance, here I will generate random odd numbers in a range of -12 and 12, now I type =ODD(RANDBETWEEN(-12, 12)) into a cell, then press Enter key. If you need, you can drag the fill handle to fill a range with this formula.
Randomize integers, dates, times, strings or custom list in Excel
If you are insterested in inserting random integers, dates, times, text strings and custom list, you can free install Kutools for Excel and apply its Insert Random Data utility to achieve the tasks.
Kutools for Excel, with more than 300 handy functions, makes your jobs more easier. |
After free installing Kutools for Excel, please do as below:
Select a range and click Kutools > Insert > Insert Random Data.
Supercharge Your Excel Skills with Kutools for Excel, and Experience Efficiency Like Never Before. Kutools for Excel Offers Over 300 Advanced Features to Boost Productivity and Save Time. Click Here to Get The Feature You Need The Most...Best Office Productivity Tools
Office Tab Brings Tabbed interface to Office, and Make Your Work Much Easier