Skip to content

Instantly share code, notes, and snippets.

@adurpas
Created December 2, 2012 18:22
Show Gist options
  • Save adurpas/4190311 to your computer and use it in GitHub Desktop.
Save adurpas/4190311 to your computer and use it in GitHub Desktop.
Main #1
// ISU laboratory session #9, exercise #1.
#include <iostream>
#include "SmartString.hpp"
using namespace std;
int main (int argc , char * argv [])
{
{
SmartString ss(new string("Hello world"));
cout << "String length: " << ss->length() << endl;
if(ss->find("world") != string::npos)
{
cout << "The 'ss' string does contain 'world'" << endl;
}
else
{
cout << "The 'ss' string does NOT contain 'world '" << endl;
}
}
int i;
cin >> i;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment