If you just check out the examples (rather than try to get all the info in the tables) in these two articles you should be able to translate your C++ code into C easily enough!?
Actually, it limits the (safe) maximum length of the name to 99 chars; you need to set aside one element in the array for the null terminator.
but I havn't seen scanf yet
Did you check out the examples in the reference entires that Softrix and I pointer you at? They include pretty much everything you need to sort out your code.