{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

wraptest.cc - Wrap<double> w = new...

Info iconThis preview shows page 1. Sign up to view the full content.

View Full Document Right Arrow Icon
#include <iostream> //#include "Wrap.h" #include "Wrap.cc" using namespace std; void testint() { Wrap<int>* w = new Wrap<int>(5); //cout << *w; w->display(cout); int v = w->get(); cout << v << endl; w->set(8); //cout << *w; w->display(cout); delete w; } void testdouble() {
Background image of page 1
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: Wrap<double>* w = new Wrap<double>(5.5); //cout << *w; w->display(cout); double v = w->get(); cout << v << endl; w->set(8.8); //cout << *w; w->display(cout); delete w; } int main(int argc, char* argv) { testint(); testdouble(); }...
View Full Document

{[ snackBarMessage ]}

Ask a homework question - tutors are online