3
I’m using the book Data Structures: Algorithms, Complexity Analysis and Implementations in JAVA and C/C++ as it helps with practical implementation examples.
In chapter 1 there is the following excerpt that left me in doubt
The running time of an algorithm will be represented by a cost function T, where T(n) is the measure of the time needed to execute an algorithm for a problem of size n. Hence, T is called 'time complexity function' of the algorithm. If T(n) is the memory measure needed to execute the algorithm, then T is called 'space complexity function. According to Ziviani (2004), it is important to emphasize that T(n) does not directly represent the execution time, but the number of times a relevant operation is executed.
Why does the author refer to T in two different ways? it became difficult to understand this variation, has some context in which another expression should be used?