gets() doesn't "give" the name. It "gets" the name (and you shouldn't actually be using it, anyway).

To print the name, use printf() with the %s format

As soon as you can, switch from using...