home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 22 gnu / 22-gnu.zip / sampl254.zip / gcc2 / samples / sample2.cc < prev    next >
Text File  |  1992-04-16  |  300b  |  23 lines

  1. #include <iostream.h>
  2.  
  3. class sampleclass {
  4.    public:
  5.        sampleclass()
  6.        {
  7.           cout << "constructor\n";
  8.        }
  9.  
  10.        ~sampleclass()
  11.        {
  12.           cout << "destructor\n";
  13.        }
  14. };
  15.  
  16. sampleclass GlobalInstance;
  17.  
  18. main()
  19. {
  20.     cout << "hello world\n";
  21. }
  22.  
  23.