Thursday, January 9, 2025

easy google online assessment

I just did a Google online assessment. The first problem was to count the number of 4 digit decimal numbers whose digits sum to k. The answer is simply the kth entry of this convolution:

[1,1,1,1,1,1,1,1,1,1] * [1,1,1,1,1,1,1,1,1,1] * [1,1,1,1,1,1,1,1,1,1] * [1,1,1,1,1,1,1,1,1,1]

Here's a related problem.