More comments in code samples?

Hello everyone,
Everyday I work on projects full of comments, which are required and extremely helpful.
On my free time I come on CodinGame and when it comes to reviewing code, most of the time there are absolutely none!
As it bothered me a lot for a long time, I came here because I wish a solution could be found to make people add comments to their code (when necessary) and make it more readable so we could learn faster.
Any ideas?
I think the only way would be to add a badge or some kind of reward, but I think it is childish and someone might have a way better solution.
Thank you, have a pleasant day!

1 Like

#no comment says the codingame community :sweat_smile:.

You can upvote solution code that you like; there are definitively some people around that provide extensive comments, to reward them you could upvote their code.

Also, I think more than a few players are happy to explain code snippets to you if you send them a PM about their code, or if you ask about it on the forum thread of a respective puzzle.

But I think ultimately this site is to learn coding by doing - solving a variety of puzzles at the level you are at, and trying at higher levels. To learn code by seeing code from others is just a side benefit, and you can already thank players that they publish their nice work, rather than also expecting them to comment all their work as well.

1 Like

:sweat_smile:
I wrote this on the forum because I reviewed some solutions on the last challenge The Lost Files.
Most of the solutions were pretty easily understandable but absolutely none of them had comments.
What made me write here is one solution with very few lines of code, like a quarter of every other solution I had reviewed.
So I tried to read it and couldn’t understand how it worked because, you see, those lines of code which do 36 things at once with lists of lists…
It seems to be a very elegant solution but I still have to spend a lot of time trying to figure out what does what.
I love these kind of solutions and I never put comments because I don’t have time to come back later and I’m convinced that no one will ever read my code.
But if we found a solution to this, it would be of great help, like when I work on other websites.
It makes me improve even faster and I wish CodinGame would do something about it :slightly_smiling_face:
(bottle in the water here)

1 Like