You can use $(this)
to target current clicked element:
$('.content').click(function() {
$(this).addClass('comment');
});
Also id
is unique, you should use class for your anchors instead.
If you want to add class comment on .content
div when click on the anchor than you can use:
$('.content a').on('click',function(e){
e.preventDefault();
$(this).closest('.content').addClass('comment');
})