Click here to Skip to main content
15,888,303 members
Home / Discussions / C / C++ / MFC
   

C / C++ / MFC

 
GeneralRe: Change mouse pointer... Pin
sujeet22-May-09 2:55
sujeet22-May-09 2:55 
QuestionAbout data combination Pin
Chrissie.ja20-May-09 22:10
Chrissie.ja20-May-09 22:10 
AnswerRe: About data combination Pin
ThatsAlok20-May-09 22:58
ThatsAlok20-May-09 22:58 
GeneralRe: About data combination Pin
Chrissie.ja20-May-09 23:18
Chrissie.ja20-May-09 23:18 
GeneralRe: About data combination Pin
CPallini20-May-09 23:31
mveCPallini20-May-09 23:31 
GeneralRe: About data combination Pin
ThatsAlok20-May-09 23:48
ThatsAlok20-May-09 23:48 
GeneralRe: About data combination Pin
Chrissie.ja21-May-09 1:14
Chrissie.ja21-May-09 1:14 
GeneralRe: About data combination Pin
CPallini21-May-09 2:08
mveCPallini21-May-09 2:08 
#include <vector>
#include <iostream>
using namespace std;
void step(unsigned int level, vector < vector <char> > & v, vector <char> & res);

void main()
{

  vector< char > v1;
  vector< char > v2;
  vector< char > v3;
  vector< char > v4;
  vector< char > v5;

  vector < vector < char > > v;

  v1.push_back('a');v1.push_back('b');v1.push_back('c');
  v2.push_back('d');v2.push_back('e');
  v3.push_back('f');v3.push_back('g');v3.push_back('h');
  v4.push_back('i');v4.push_back('j');v4.push_back('k');v4.push_back('l');

  vector < char > res;
  

  v.push_back(v1);v.push_back(v2);v.push_back(v3);v.push_back(v4);
  res.resize(v.size());

  step(0, v, res);
}


void step(unsigned  int level, vector < vector <char> > & v, vector <char> & res)
{
  for (unsigned int i=0; i<v[level].size(); i++)
  {
    res[level] = v[level][i];
    if ( level == v.size()-1) 
    {
       for (unsigned int k=0; k<res.size(); k++)
       {
         cout << res[k];
       }
       cout << endl;
    }
    else
    {
      step(level + 1, v, res);
    }
  }
}

Smile | :)

If the Lord God Almighty had consulted me before embarking upon the Creation, I would have recommended something simpler.
-- Alfonso the Wise, 13th Century King of Castile.

This is going on my arrogant assumptions. You may have a superb reason why I'm completely wrong.
-- Iain Clarke

[My articles]

GeneralRe: About data combination Pin
Chrissie.ja21-May-09 2:12
Chrissie.ja21-May-09 2:12 
QuestionDoubt in different Image formats? Pin
kapardhi20-May-09 21:42
kapardhi20-May-09 21:42 
AnswerRe: Doubt in different Image formats? Pin
Chris Losinger21-May-09 3:19
professionalChris Losinger21-May-09 3:19 
AnswerRe: Doubt in different Image formats? Pin
Stuart Dootson21-May-09 5:47
professionalStuart Dootson21-May-09 5:47 
QuestionHow to create machine certificate. Pin
deadlyabbas20-May-09 21:26
deadlyabbas20-May-09 21:26 
QuestionHow to use an image converter in my application? Pin
kapardhi20-May-09 21:17
kapardhi20-May-09 21:17 
AnswerRe: How to use an image converter in my application? Pin
Hamid_RT20-May-09 21:20
Hamid_RT20-May-09 21:20 
GeneralRe: How to use an image converter in my application? Pin
kapardhi20-May-09 21:31
kapardhi20-May-09 21:31 
AnswerRe: How to use an image converter in my application? Pin
ThatsAlok20-May-09 21:24
ThatsAlok20-May-09 21:24 
GeneralRe: How to use an image converter in my application? Pin
kapardhi20-May-09 21:34
kapardhi20-May-09 21:34 
GeneralRe: How to use an image converter in my application? Pin
ThatsAlok20-May-09 21:54
ThatsAlok20-May-09 21:54 
Questiondelete operator in C++ Pin
QuickDeveloper20-May-09 20:48
QuickDeveloper20-May-09 20:48 
AnswerRe: delete operator in C++ Pin
Cedric Moonen20-May-09 21:37
Cedric Moonen20-May-09 21:37 
Questionpassing value from C# to c++ Pin
mutpan20-May-09 19:40
mutpan20-May-09 19:40 
GeneralRe: passing value from C# to c++ Pin
norish21-May-09 1:34
norish21-May-09 1:34 
QuestionTextOut and distance between strings Pin
prithaa20-May-09 18:35
prithaa20-May-09 18:35 
GeneralRe: TextOut and distance between strings Pin
Michael Dunn20-May-09 18:48
sitebuilderMichael Dunn20-May-09 18:48 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.