Giving input strings

how to declare string input for n strings we don’t know the number of strings to read

if string doesn’t contain space you can do something like this

string s;
while(cin>>s)
{

}