Hi I'm having trouble figuring out how to store something the user inputs into a dynamic character array? This is all I have so far:
Code:#include <iostream> #include <fstream> #include <iomanip> #include <string> using namespace std; int main() { string userString; cout << "Enter a string value: "; cin >> userString; cout << endl << endl; cout << "You entered: " << userString << ". *NOTE* We are not counting anything after white spaces! Count: " << userString.length(); cout << endl << endl; return 0; }



LinkBack URL
About LinkBacks



