11 ms·
In these 3 functions: o.calcLineCount() o.calcWordCount() o.calcCharCount() you're splitting the file content 2 times, but you can do everything in only 1 p
by yandrypozo 10y ago
In these 3 functions:
o.calcLineCount()
o.calcWordCount()
o.calcCharCount()
you're splitting the file content 2 times, but you can do everything in only 1 pass.
- v_adhithyan 10y agooh ok. do i need to iterate each character and check for delimiter and increase count?