Solve a problem where you can take 1, 2, or 3 steps at a time and compute the number of ways to cover n steps.
Implement count_ways(n), which returns the number of distinct ordered sequences of moves that cover exactly n steps. Treat n = 0 as one valid way: taking no steps. Return the result as an integer.
n is a non-negative integer. The function returns an integer count.
def count_ways(n):