Help with a problem

I have this assignment due and its a bit tricky, i was wondering how is it possible to incoporate both C-string and a string object at the same time. Any help would be very very appreciated. thank you all in advance. Here is the actual problem from the book.

Write a function that accepts either a pointer to a C-string, or a string object, as its argument. The function should return the character that appears most frequently in the string. Demonstrate the function in a complete program.

My teacher usually has us do this is seperate .cpp files because its easier to go back and fix things. which is nice but a bit more confusing sometimes. He also likes us to use a .h file and include it in any .cpp files that will need it. Just thought id let you guys know if this is gonna help or if it would matter or anything.

Thank you very much for your help Nathan, the website you suggested seemed to help a bit with other questions i had as well. The little snippet you had helped as well. Thank you very much. I'm quite new to this and i appreciate all the help