Joined
Last Seen
0 Reputation Points
Unknown Quality Score
No one has voted on any posts yet. Votes from other community members are used to determine a member's reputation amongst their peers.
0 Endorsements
Ranked #107.41K
~2K People Reached
Favorite Forums
Computer Science
x
1
Re:
Plz tell me how I would calculate time complexity of the program: int i = N; while (i > 0) { int Sum = 0; int j; for (j = 0; j < i; j++) Sum++; cout << Sum << endl; i--; } thnx in advance |
|
Re:
Hi everybody, I need some helpings to calculate time complexity(worst case, best case and average) for following code : int m = A[0]; for (int i=1;i<n;i++) {if (A[i]>m) m = A[i];} int k = 0; for(int i = 0; i<n;i++) {if(A[i] == m) k++;} Thank you ........................ |