How do I make this ...

Look like this:

Normally I would do it by dragging the bottom right corner, but that's not so easy if you have 200 or 300 names. Is there a way to automate the process?
How do I make this ...

Look like this:

Normally I would do it by dragging the bottom right corner, but that's not so easy if you have 200 or 300 names. Is there a way to automate the process?