text cover

Data Abstraction and Problem Solving with C++

Walls and Mirrors

by Frank M. Carrano

Addison Wesley Logo

SphereDemo.cpp

Go to the documentation of this file.
00001 
00016 #include <iostream>
00017 #include "Sphere.h"
00018 
00019 using namespace std;
00020 
00021 int main()
00022 {
00023    Sphere unitSphere;         // radius is 1.0
00024    Sphere mySphere(5.1);      // radius is 5.1
00025 
00026    unitSphere.displayStatistics();
00027    mySphere.setRadius(4.2);   // resets radius to 4.2
00028    cout << mySphere.getDiameter() << endl;
00029 
00030    return 0;
00031 }  // end main

Generated on Sun Aug 27 11:56:47 2006 for AWLogo by  doxygen 1.4.6