Question: Question 1: Using the statement execution times defined for HAL, calculate the running time for the given function (Show all steps to get full marks).
Question 1:
Using the statement execution times defined for HAL, calculate the running time for the given function (Show all steps to get full marks).
static int freq(int f[]){ 50(function dec) + 10? 9For int array?)
int k = 1; int j = 0; 10 + 10
while(j < f.length){
if(f[j] * 2 == j)
k = k * f[j];
j++;
}
return k;10
}
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
