File tree 7 files changed +11
-6
lines changed
7 files changed +11
-6
lines changed Original file line number Diff line number Diff line change @@ -90,11 +90,11 @@ void Env::calcLevel() {
90
90
ratio = 0.5 ;
91
91
}
92
92
else {
93
- (double )statList[i]->getKnown () / statList[i]->getTotal ();
93
+ ratio = (double )statList[i]->getKnown () / statList[i]->getTotal ();
94
94
}
95
95
if (ratio > 0.9 ) {
96
96
basic->setLevel ((i + 1 ) * (LEVEL_MAX / DIFFI_NUM)
97
- + (LEVEL_MAX / DIFFI_NUM) * ratio * 0.5 );
97
+ + (LEVEL_MAX / DIFFI_NUM) * ratio * 0.8 );
98
98
if (basic->getLevel () > LEVEL_MAX) {
99
99
basic->setLevel (LEVEL_MAX);
100
100
}
Original file line number Diff line number Diff line change 2
2
#define ENV_H
3
3
4
4
#include < fstream>
5
+ #include < cstdlib>
6
+ #include < ctime>
5
7
#include " util.h"
6
8
#include " info.h"
7
9
#include " def.h"
Original file line number Diff line number Diff line change @@ -74,6 +74,7 @@ string LearnOneWord::getWord() {
74
74
75
75
void LearnOneWord::ask () {
76
76
word = sstra->next (diffi);
77
+ cout << " @@@@diffi: " << diffi << endl;
77
78
fstra->setWord (word);
78
79
cout << fstra->display ();
79
80
}
Original file line number Diff line number Diff line change @@ -11,9 +11,10 @@ void Program::show() {
11
11
login ();
12
12
for (;;) {
13
13
// TODO
14
- RandomSelection* rs = new RandomSelection (env);
14
+ // RandomSelection* rs = new RandomSelection(env);
15
+ SmartSelection* ss = new SmartSelection (env);
15
16
RemOrNotForm* ronf = new RemOrNotForm ();
16
- MainInterface mi (env, rs , ronf);
17
+ MainInterface mi (env, ss , ronf);
17
18
mi.work ();
18
19
if (mi.toQuit ()) {
19
20
break ;
Original file line number Diff line number Diff line change 1
1
#include " strategy.h"
2
2
3
3
SelectStrategy::SelectStrategy (Env* env) : env(env), diffi(0 ) {
4
+ srand (time (0 ));
4
5
}
5
6
6
7
string SelectStrategy::next (int & difficulty) {
@@ -67,7 +68,6 @@ RandomSelection::RandomSelection(Env* env) : SelectStrategy(env) {
67
68
}
68
69
69
70
int RandomSelection::chooseDifficulty () {
70
- srand (time (0 ));
71
71
return rand () % DIFFI_NUM;
72
72
}
73
73
Original file line number Diff line number Diff line change
1
+ !ZXCroon
Original file line number Diff line number Diff line change 1214
1214
}
1215
1215
1216
1216
*feel* {
1217
- #n. an intuitive awareness; #
1217
+ #n. an intuitive awareness;#
1218
1218
#n. the general atmosphere of a place or situation and the effect that it has on people#
1219
1219
#n. a property perceived by touch#
1220
1220
#v. undergo an emotional sensation or be in a particular state of mind#
You can’t perform that action at this time.
0 commit comments