The following are links to additional questions that our community has asked about this exercise:
This list will contain other frequently asked questions that aren’t quite as popular as the ones above.
Currently there have not been enough questions asked and answered about this exercise to populate this FAQ section.
This FAQ is built and maintained by you, the Codecademy community – help yourself and other learners like you by contributing!
Not seeing your question? It may still have been asked before – try searching for it by clicking the spyglass icon () in the top-right of this page. Still can’t find it? Ask it below by hitting the reply button below this post ().
I use it as a kinda of pointer. So when I create a new div which I’m going to put content in, I’ll put a comment saying what I’m using it for, like so:
<!-- Div for updating score-->
<div id="score">
Score: 0
</div>
It’s a nice pointer for me or other people to see as the scroll through the code, Oh hey, that’s where that div is and that’s what it does.
Thanx for the reply @stevencopeland I was thinking much the same way! It would be super useful for labeling containers and things of that nature. I’m just now starting out and hoping maybe I will get some input from experienced devs that may show other useful ways to use these comments that shed light on instances that my inexperienced self might use down the road to avoid problems. Comments seem like a very versatile tool.
I work in a Japanese company (and plan on opening my own up here soon !!) But I was wondering with the <!-- comments thing, can you use other languages in there? Some of my coworkers can’t speak English well enough to suddenly be leaving English comments in the code.
It’s important to keep in mind that your comment can be read in the page source by anyone accessing the site, so don’t leave any sensitive information in comments.
While you are writing the code, there are certain practice that needs to be developed.
For example:
What is something new you learnt while creating that code.
What is something that your code does and is a little but clever.
Is there a point in your code where you got stuck!
This is the part of the code I need to update regularly.
This part of the code needs to be revised or updated.
These examples would make you insert the comments at places which would be easier for you and others as well.