• 大小: 45KB
    文件类型: .rar
    金币: 1
    下载: 0 次
    发布日期: 2021-05-22
  • 语言: C/C++
  • 标签: 二叉树  

资源简介

二叉树(基于Mfc的程序开发),具有二叉树的先序遍历、中序遍历、后续遍历、以及非递归中序遍历、以及树形控件显示

资源截图

代码片段和文件信息

// Binary Trees.cpp : Defines the class behaviors for the application.
//

#include “stdafx.h“
#include “Binary Trees.h“

#include “MainFrm.h“
#include “Binary TreesDoc.h“
#include “Binary TreesView.h“

#ifdef _DEBUG
#define new DEBUG_NEW
#undef THIS_FILE
static char THIS_FILE[] = __FILE__;
#endif

/////////////////////////////////////////////////////////////////////////////
// CBinaryTreesApp

BEGIN_MESSAGE_MAP(CBinaryTreesApp CWinApp)
//{{AFX_MSG_MAP(CBinaryTreesApp)
ON_COMMAND(ID_APP_ABOUT OnAppAbout)
// NOTE - the ClassWizard will add and remove mapping macros here.
//    DO NOT EDIT what you see in these blocks of generated code!
//}}AFX_MSG_MAP
// Standard file based document commands
ON_COMMAND(ID_FILE_NEW CWinApp::OnFileNew)
ON_COMMAND(ID_FILE_OPEN CWinApp::OnFileOpen)
// Standard print setup command
ON_COMMAND(ID_FILE_PRINT_SETUP CWinApp::OnFilePrintSetup)
END_MESSAGE_MAP()

/////////////////////////////////////////////////////////////////////////////
// CBinaryTreesApp construction

CBinaryTreesApp::CBinaryTreesApp()
{
// TODO: add construction code here
// Place all significant initialization in InitInstance
}

/////////////////////////////////////////////////////////////////////////////
// The one and only CBinaryTreesApp object

CBinaryTreesApp theApp;

/////////////////////////////////////////////////////////////////////////////
// CBinaryTreesApp initialization

BOOL CBinaryTreesApp::InitInstance()
{
AfxEnableControlContainer();

// Standard initialization
// If you are not using these features and wish to reduce the size
//  of your final executable you should remove from the following
//  the specific initialization routines you do not need.

#ifdef _AFXDLL
Enable3dControls(); // Call this when using MFC in a shared DLL
#else
Enable3dControlsStatic(); // Call this when linking to MFC statically
#endif

// Change the registry key under which our settings are stored.
// TODO: You should modify this string to be something appropriate
// such as the name of your company or organization.
SetRegistryKey(_T(“Local AppWizard-Generated Applications“));

LoadStdProfileSettings();  // Load standard INI file options (including MRU)

// Register the application‘s document templates.  Document templates
//  serve as the connection between documents frame windows and views.

CSingleDocTemplate* pDocTemplate;
pDocTemplate = new CSingleDocTemplate(
IDR_MAINframe
RUNTIME_CLASS(CBinaryTreesDoc)
RUNTIME_CLASS(CMainframe)       // main SDI frame window
RUNTIME_CLASS(CBinaryTreesView));
AddDocTemplate(pDocTemplate);

// Parse command line for standard shell commands DDE file open
CCommandLineInfo cmdInfo;
ParseCommandLine(cmdInfo);

// Dispatch commands specified on the command line
if (!ProcessShellCommand(cmdInfo))
return FALSE;

// The one and only window has been initialized so show and update it.

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----

     文件      47372  2009-05-20 17:43   二叉树\Binary Trees.aps

     文件       3427  2009-05-20 17:46   二叉树\Binary Trees.clw

     文件       4303  2009-05-15 19:48   二叉树\Binary Trees.cpp

     文件       4893  2009-05-15 22:22   二叉树\Binary Trees.dsp

     文件        549  2009-05-15 19:48   二叉树\Binary Trees.dsw

     文件       1414  2009-05-15 19:48   二叉树\Binary Trees.h

     文件      91136  2009-05-20 17:47   二叉树\Binary Trees.ncb

     文件      48640  2009-05-20 17:47   二叉树\Binary Trees.opt

     文件       1273  2009-05-20 17:46   二叉树\Binary Trees.plg

     文件      13702  2009-05-20 17:43   二叉树\Binary Trees.rc

     文件       1845  2009-05-15 19:48   二叉树\Binary TreesDoc.cpp

     文件       1531  2009-05-15 19:48   二叉树\Binary TreesDoc.h

     文件       6061  2009-05-20 17:46   二叉树\Binary TreesView.cpp

     文件       2283  2009-05-20 16:48   二叉树\Binary TreesView.h

     文件       1635  2009-05-18 22:33   二叉树\Btrees.cpp

     文件       1395  2009-05-15 20:18   二叉树\Btrees.h

     文件       2400  2009-05-15 20:40   二叉树\MainFrm.cpp

     文件       1440  2009-05-15 20:40   二叉树\MainFrm.h

     文件       4448  2009-05-15 19:48   二叉树\ReadMe.txt

     文件       1078  2009-05-15 19:48   二叉树\res\Binary Trees.ico

     文件        404  2009-05-15 19:48   二叉树\res\Binary Trees.rc2

     文件       1078  2009-05-15 19:48   二叉树\res\Binary TreesDoc.ico

     文件        326  2009-05-15 20:25   二叉树\res\cursor1.cur

     文件       1078  2009-05-15 19:48   二叉树\res\Toolbar.bmp

     文件       1614  2009-05-19 23:04   二叉树\resource.h

     文件        214  2009-05-15 19:48   二叉树\StdAfx.cpp

     文件       1054  2009-05-15 19:48   二叉树\StdAfx.h

     文件       1133  2009-05-19 23:39   二叉树\新建 文本文档.txt

     目录          0  2011-06-10 12:52   二叉树\res

     目录          0  2011-06-10 12:52   二叉树

............此处省略3个文件信息

评论

共有 条评论