Data Structyre and Algorithms:
Solve solve this on emergency basis:
find running Time complexity T(n) and Space complexity S(n). Also show in big-O notation.
Code Segment 5
Algorithm Max (int a[], int size)
int max = a[0];
for (int i = 1; i < size / 2; ++i)
{
if (max < a[i])
max = a[i];
}
for (int j = 1; j <= size * size; ++j)
{
++max;
cout << max;
}
