문제

Do Comments in code increase time complexity of a program.?

I have many running applications wherein there are codes which are commented within functions.

These commented codes are of 500 lines within a function and the actual code of just 10 lines. Will this affect the Time complexity ?

These comments will make the size of the application larger but will it affect the efficiency of application when the respective function with commented code will be called?

도움이 되었습니까?

해결책

Comments are typically removed before compilation, so they don't affect the code size. Secondly, time complexity refers to the asymptotic time taken for an algorithm, for example n^2 or log(n). See http://en.wikipedia.org/wiki/Big_O_notation.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top