Click here to Skip to main content
Click here to Skip to main content
Add your own
alternative version

Combinations in C++

, 13 Sep 2009 CPOL
An article on finding combinations.
// TestComboDlg.h : header file
#include "combination.h"

#if !defined(AFX_TESTCOMBODLG_H__DE323766_C018_11D7_ACBC_F9366451BC33__INCLUDED_)
#define AFX_TESTCOMBODLG_H__DE323766_C018_11D7_ACBC_F9366451BC33__INCLUDED_

#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000

// CTestComboDlg dialog

class CTestComboDlg : public CDialog
// Construction
	CTestComboDlg(CWnd* pParent = NULL);	// standard constructor

// Dialog Data
	CProgressCtrl	c_progressbar;
	int		m_n_seq;
	int		m_r_seq;
	CString	m_complete;
	int		m_radio;

	// ClassWizard generated virtual function overrides
	virtual void DoDataExchange(CDataExchange* pDX);	// DDX/DDV support

// Implementation
	HICON m_hIcon;
	std::map<char,int> mc;
	__int64 fact(int num);
	__int64 NumOfCombo();
	void InitialiseMap();
	bool CheckMap();
	void char_combination(char n[],int n_column,
       char r[], int r_size, int r_column, int loop);
  void temp(char *begin,char* end);

	// Generated message map functions
	virtual BOOL OnInitDialog();
	afx_msg void OnPaint();
	afx_msg HCURSOR OnQueryDragIcon();
	afx_msg void OnStart();

// Microsoft Visual C++ will insert additional declarations immediately before the previous line.

#endif // !defined(AFX_TESTCOMBODLG_H__DE323766_C018_11D7_ACBC_F9366451BC33__INCLUDED_)

By viewing downloads associated with this article you agree to the Terms of Service and the article's licence.

If a file you wish to view isn't highlighted, and is a text file (not binary), please let us know and we'll add colourisation support for it.


This article, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)


About the Author

Shao Voon Wong
Software Developer
Singapore Singapore
No Biography provided

| Advertise | Privacy | Terms of Use | Mobile
Web02 | 2.8.150123.1 | Last Updated 13 Sep 2009
Article Copyright 2003 by Shao Voon Wong
Everything else Copyright © CodeProject, 1999-2015
Layout: fixed | fluid