I need to generate a string that reads like this...

Input text:
PETER
STEVE
JOHN

Output text:
PETER (1),
PETER (2),