logo

Crowdly

Browser

Add to Chrome

int find_c(int n)   int i,j,c   for(i=1000; i > 0; i--)     for(j=0; j ...

✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.

int find_c(int n)

  int i,j,c

  for(i=1000; i > 0; i--)

    for(j=0; j < 4*n*n; j++)

      c++

  for(i=c; i > 0; i--)

    if(random(0...999) > 500)

      for(j=1; j < 900; j=j*3)

        c++

    else

      for(j=n/2; j < n; j++)

        c++

  return c

Mis on antud algoritmi halvima juhu keerukus O-notatsioonis sõltuvalt sisendparameetrist n:
0%
0%
0%
0%
0%
0%
0%
0%
0%
0%
More questions like this

Want instant access to all verified answers on moodle.taltech.ee?

Get Unlimited Answers To Exam Questions - Install Crowdly Extension Now!

Browser

Add to Chrome