Shell: Create a Comma Separated String

I recently needed to generate a string with comma separated values, based on iterating a range of numbers (e.g. we should get the following output where n = 3).
I only had Shell available to me so I couldn’t shell out into Python or Ruby, for example. That means it’s Bash scripting time!