Mark Mintoff My superpower is common sense


Actual Line Count

Often times, we find ourselves designing throwaway code which only fulfills a one-time requirement. The following piece of coding is one such piece of code.

What it is designed to do is generate an actual count of lines of code within an SQL file (it can be modified accordingly to work with other language files).

In order to do this, the code iterates through the lines of text and skips counting on empty lines, as well as comment blocks.

As it turns out, the 177,251 lines of code file I scanned has 154,109 lines of actual code. Handy!

VN:F [1.9.22_1171]
Rating: 0.0/5 (0 votes cast)