>I need to know how to use gets in this code
That's simple, don't. But there's nothing "technically" wrong with how you're using it now. Did you test it?

>because I am told to use it by my lecture...
I'd ask you to smack him for me if I thought that you would. You should consider finding someone better qualified to teach you C.

[edit]
Or did you stumble on the whole scanf/unformatted input problem? It's asked often, and answered just as often if you want to search the forum for it.
[/edit]