displays a string with pointer notation : string create « Data Types « C++ Tutorial






#include <iostream>  
  using namespace std;  
    
  int main(){  
     void dispstr(char*);
     char str[] = "Idle people have the least leisure.";  
    
     dispstr(str);      
     return 0;  
  }  

  void dispstr(char* ps)  
  {  
     while( *ps )       
        cout << *ps++;  
     cout << endl;  
  }








2.23.string create
2.23.1.Create a string base on the start and end of another string
2.23.2.displays a string with pointer notation
2.23.3.copies one string to another with pointers