Cache Hit Rate
Given booleans where true means hit, return the hit rate rounded to six decimals.
Examples
EXAMPLE WALKTHROUGHmixed
A guided view of the published example, not a trace of your code.
INPUT
[[true,false,true]]TASKcache_hit_rate()
EXPECTED OUTPUT
0.666667Start with the input values shown in this example.
Example 1 of 2
Input: events = [true,false,true]
Output: 0.666667
Explanation: mixed
Input: events = []
Output: 0
Explanation: empty
Hint 1
Booleans can be summed in Python.