-1

Assume a machine has a throughput of 70 ops/s. Say we have an algorithm with time complexity T(n) = 2n^2 + 120

Determine how many hours will it take the machine to execute said algorithm for an input of size n = 8.


Is this correct?

T(n) = 2n^2 + 120

T(8) = 2(8)^2 + 120 = 248 * 70 * 1000

Please help.

4

1 に答える 1

2

いくつかのヒント:

  • あなたのプログラムが 70 回の操作を行う場合、何秒かかりますか?

  • 1時間は何秒?(1分は何秒、1時間は何分?)

于 2012-09-10T02:02:12.607 に答える