Should one comment differently in functional languages

Posted by Tom Squires on Programmers See other posts from Programmers or by Tom Squires
Published on 2011-11-17T11:22:53Z Indexed on 2011/11/17 18:07 UTC
Read the original article Hit count: 264

I'm just getting started with functional programming and I'm wondering the correct way to comment my code.

It seems a little redundant to comment a short function as the names and signature already should tell you everything you need to know. Commenting larger functions also seems a little redundant since they are generally comprised of smaller self-descriptive functions.

What is the correct way to comment a functional program? Should I use the same approach as in iterative programming?

© Programmers or respective owner

Related posts about best-practices

Related posts about functional-programming