Hi i just wanted to ask whether we cud use #include<string> and declare a data type called 'string' eg. string ch;? and where is "using namespace std" used?
The Standard Template Directory (or Definitions... or Defined types...) is a namespace with defined C and C++ types/functions/objects.
Without the "using namespace std" you would have to make calls to the std's objects in this way--
//without the using namespace std
std::cout << "Making a call to the cout and endl objects from namespace std" << std::endl;
--and about your first question, I'm not sure if I'm answering your question correctly when I say this, but yes you can declare a variable of type String in that way... however I'd suggest that you use the call to the constructor of the string object in this way--