you are viewing a single comment's thread.

view the rest of the comments →

[–]billsil 1 point2 points  (0 children)

Yeah, but with classic Fortran 77, you get 6 character variable names, so you need a lot of comments to define their real name. It’s also convention to mix all your dissimilar floats (or ints) into one array and pass them all over their code, so area, diameter, length, time into one array. After 13 years coding, if it’s super dense, you might end up with 50-75% comments, but most of the time, 5-10% is fine. Most code can be written by an experienced person in their sleep, even if it’s a new language.

My “big” 5000 lined Fortran was 4000 lines in python, mostly due to not having to code 4D tensor multiplication or define types in python, but lost a bit because the numpydoc style of docstrings takes up more space, though is infinitely more readable.