Derive an algorithm from two given algorithms
  • Posted: 4 years ago
  • Updated: 3 years ago
  • Edit
  • answers (1)
  • views (1897)

Can you write a function using the two algorithms in Selection of algorithm with different running time that works fast for input irrespective of size?


Posted Answers




If input_size < = 100
execute algorithm with running time 2n^{2}
else
execute algorithm with running time 200n

You need to Sign In to post your solution.