Help need! on effective dictionary

I want to do> when final output have 1 char repeated more then 3 times that generated line ignore and don't place in to the output file.

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
  


#include <iostream>
#include <fstream>
#include<string>
#include<sstream>
#include<stdio.h>
#include<string.h>
using namespace std;

int main()
{
char finalchar[9];
int y = 0;
int pwstr[15];
char password[]={'a','b','c','d','e','f','0','1','2','3','4','5','6','7','8','9'};
int maxclength=sizeof(password);
cout<<maxclength<<endl;
int minlength=10;
--minlength;
int curlength=0;
int curchar=0;
bool a=true;
//string str[9];
//int cnt=0;
string comper(string pass);


if(curlength<minlength)
{
curlength=minlength;
for(int x=0; x<=curlength; x++)
{
pwstr[x]=0;
}
}

ofstream pwout("password.lst");

//start:
for(int count=0; curlength<16; count++)
{
if(count==maxclength)
{
while(a==true)
{

if(pwstr[curchar]==15)
{
if(curchar==curlength)
{
for(int x=curlength; x>0; --x)
{
pwstr[x]=0;
}
curlength++;
cout << curlength;
pwstr[curlength]=0;
a=false;
}

else
curchar++;

}

else
{
for(int x=--curchar; x>=0; --x)
{
pwstr[x]=0;
}++curchar;
pwstr[curchar]++;
a=false;
}
}
a=true;
curchar=0;
count=0;
}

pwstr[curchar]=count;
for(int x=curlength; x>=0; x--)
{

finalchar[x]=password[pwstr[x]];

}


for( y=curlength; y>=0; y--)
{
//str[y] = finalchar[y];
//cout<<finalchar[y];
pwout<<finalchar[y];



if(y==0)
{

/*this is the final string output to file*/
pwout << endl;


// final.

}
}

}

return 0;
}




Output:
aaaaaaaaaa
aaaaaaaaab
aaaaaaaaac
aaaaaaaaad
aaaaaaaaae
aaaaaaaaaf
aaaaaaaaa0
aaaaaaaaa1
aaaaaaaaa2
aaaaaaaaa3
aaaaaaaaa4
aaaaaaaaa5
aaaaaaaaa6
aaaaaaaaa7
aaaaaaaaa8
aaaaaaaaa9
aaaaaaaaba
aaaaaaaabb
aaaaaaaabc
aaaaaaaabd
.
.
.
9999999999

----------------------
I need help on the out put>
let say first & 2nd line of output : aaaaaaaaaa (a is repeated 10 times)
aaaaaaaaab (a is repeated 9 times)
first line
2nd line

after number of line later output will be:
aaaa12aaaa
( a is repeated 8 times but in two parts )
same thing happens for b , c,d,e ever char in char password[]
I want to do> when final output have 1 char repeated more then 3 times that generated line ignore and don't place in to the output file. like:

aaa1cb7aaa(ignore)
aaa245fdac(ignore)
dfcafff128(ignore)

aabbccddee -> ok
1234567899 -> ok

Can any body help me ?
Last edited on
Topic archived. No new replies allowed.