StrNum::StrNum( int ) (constructor)
Create a StrNum
, either unset or with a value.
Virtual? |
No |
|
Class |
||
Arguments |
|
the number to store (optional) |
Returns |
|
Notes
A StrNum
always stores numbers using base ten.
To create a StrNum
without a value, call StrNum()
without an
argument.
Example
The following example creates a StrNum
and displays it:
#include <iostream> #include <stdhdrs.h> #include <strbuf.h> int main( int argc, char **argv ) { StrNum sn = StrNum( 1666 ); cout << "sn.Text() returns \"" << sn.Text() << "\"\n"; }
Executing the preceding code produces the following output:
sn.Text() returns "1666"