The number of functions , from the setto the set such that , for every , is ______.
Solution
Core idea. Independent choices at each input multiply to give the number of functions.
Concept refresher. If one choice can be made in ways and an independent second choice in ways, both can be made together in
ways.
Picture the situation. Since , the set is . The set is . For each in the value can be any element of not exceeding .
Approach. Count the allowed squares for each input and multiply.
Step 1: The bounds
For to 9 the bound takes the values 5, 2, 1, 2, 5, 10, 17, 26 and 37 in turn.
Step 2: The count
The perfect squares within these bounds number 2, 1, 1, 1, 2, 3, 4, 5 and 6, so the number of functions is .
Answer. 1440
Sanity check. For the bound is 37, and the squares 1, 4, 9, 16, 25 and 36 all fit, which is 6 choices.
Common wrong answers
- 0: Dropping the in the bound leaves no square at , which gives 0.
Key takeaway
The trap. The natural numbers start at 1, so the smallest square is 1.
How toppers think. They tabulate the bound and the number of squares side by side.
Remember.