New course! Every coder should learn Generative AI!
Try a free lesson0
Im going to provide you the functions needed to achieve that. I leave the string input to you. Hint:
getline(cin, stringVarName)
http://www.sololearn.com/app/cplusplus/playground/c2plxYQ1MEpR/