# On golfing suggestions

These questions involve the practice of commenting on another user's answers to suggest a shortening of the code.

Which of these are polite? Which are best practices?

• Commenting on an answer to indicate that a shorter solution in the same language has been posted (for example, this Perl 5 answer to FizzBuzz has more votes than this one despite being longer)
• Giving credit to a user who suggests an optimization (e.g. in my answer here):

# Pyth, 21 20 bytes

-1 byte by Dennis

c/J-*3.d3C\ᙹ4T+33J

• Upvoting an answer because one suggests an optimization for it, to 'cancel out criticism'

## It's nice to include an edit in the post, referencing the user

Since comments tend to get removed by the user (or by a moderator) after they've been addressed, it is good practice to include a reference to the user for their suggested improvement(s).

• Thanks to [user] for golf help!
• -x bytes by [user]
• etc...

Upvotes are optional, of course, but giving credit may make the user more inclined to give you one.

Don't comment on an answer pointing to another answer that's shorter unless it really matters (like if there can only be one answer per language.) It seems rude.

• Just so you know, edc65's answer is shorter. ;) Oct 2 '15 at 15:15

I'm not sure to understand point 1.

If I find a way (or many ways) to shorten an existing answer, I'll put that in a comment. When (and if) my suggestion is accepted, I will probably upvote the answer just for the pleasure of vote for myself.

But if I find a different way, I'll post an answer

• I was referring to pointing out someone else's shorter answer. Sep 27 '15 at 14:43
• @ThomasKwa clearer now. I'd say no if the other anser is mine - blatant self-promotion Sep 27 '15 at 15:02