NPV & RAND Functions
Calculate investment value and generate random numbers
NPV & RAND Functions
Two useful functions: one for money decisions, one for random numbers!
RAND Function
Generates a random number between 0 and 1.
=RAND()
Every time you press Enter, it gives a new random number!
| Formula | Example Results |
|---|---|
| =RAND() | 0.4521 |
| =RAND() | 0.8934 |
| =RAND() | 0.1267 |

Random Number in a Range
Random between 1 and 100:
=RAND()*100
Random whole number 1 to 100:
=RANDBETWEEN(1, 100)
| Formula | Result |
|---|---|
| =RANDBETWEEN(1, 10) | Random 1-10 |
| =RANDBETWEEN(1, 100) | Random 1-100 |
| =RANDBETWEEN(50, 100) | Random 50-100 |
RAND Uses
- Pick random winners
- Create test data
- Shuffle a list
- Random sampling
NPV Function
NPV = Net Present Value
Tells you if an investment is worth it today.
Simple idea: Money today is worth more than money later.
NPV Formula
=NPV(rate, value1, value2, ...)
- rate = discount rate (like interest rate)
- values = future cash flows (money you'll get)
NPV Example
You invest and expect to get:
- Year 1: $1000
- Year 2: $1500
- Year 3: $2000
Discount rate: 10%
=NPV(10%, 1000, 1500, 2000)
Result → $3756.57
This means future $4500 is worth $3756 today.

NPV with Initial Investment
If you pay $3000 upfront:
=NPV(10%, 1000, 1500, 2000) - 3000
Result → $756.57 (profit!)
If result is positive → Good investment!
If result is negative → Bad investment!
Quick Reference
| Function | What It Does |
|---|---|
| RAND() | Random number 0-1 |
| RANDBETWEEN(min, max) | Random whole number in range |
| NPV(rate, values) | Present value of future money |
Summary
RAND:
- Makes random numbers
- Use RANDBETWEEN for whole numbers
- Changes every time sheet recalculates
NPV:
- Calculates investment value today
- Positive = good investment
- Negative = bad investment