Answer:
13680
Explanation:
Since we have number from 0 to 39 inclusive, there are 40 number all together.
Now there are 20 odd numbers and 20 even numbers since half of the the numbers are odd and half even.
Now, since we require 3 numbers for our locker combination which are either all even or all odd, the number of ways we can arrange 3 numbers from 20 when the order matters is ²⁰P₃ = 6480 ways for either odd or even numbers. So, for both odd and even numbers, we have the sum of even and odd number of ways ²⁰P₃ + ²⁰P₃ = 2 × ²⁰P₃ = 2 × 6480 = 13680. So, we have 13680 combinations of locks.