Linux command to repeat a string n times – Super User

I was working on something and needed to output the string n times. I have required this even to print a line with \’-\’ or \’=\’ but this time I badly wanted it in bash. So I searched google and found this:

printf \”Amit Agarwal%.0s\” {1..5}

Explanations and other examples: http://superuser.com/questions/86340/linux-command-to-repeat-a-string-n-times

\"Enhanced