All problems
Kernel Launch Overhead
Problem
Compute the total kernel launch overhead in milliseconds: num_kernels * overhead_us / 1000.
The signature is kernel_launch_overhead(num_kernels, overhead_us).
Hint
Launch overhead matters most for small kernels and eager execution.
Test cases
case 1
in: [100,5]
expected: 0.5
case 2
in: [1,3]
expected: 0.003
case 3
in: [1000,2.5]
expected: 2.5
case 4
in: [0,5]
expected: 0
Starter codePython
def kernel_launch_overhead(num_kernels, overhead_us):
# Your code here
pass4 test cases · run your code against them in the editor