for (int i = 1; i <= (int)NCLASSES; i++) {
if (classes[i].threshold >= points) {
speak(classes[i].message);
- int nxt = classes[i].threshold + 1 - points;
- rspeak(NEXT_HIGHER, nxt, nxt);
+ if (i < (int)NCLASSES) {
+ int nxt = classes[i].threshold + 1 - points;
+ rspeak(NEXT_HIGHER, nxt, nxt);
+ } else {
+ rspeak(NO_HIGHER);
+ }
exit(EXIT_SUCCESS);
}
}
rspeak(OFF_SCALE);
- rspeak(NO_HIGHER);
exit(EXIT_SUCCESS);
}
It may interest you to know that the Dungeon-Master himself has, to
my knowledge, never achieved this threshold in fewer than 330 turns.'
-To achieve the next higher rating, you need 969 more points.
+To achieve the next higher rating would be a neat trick!
+Congratulations!!
You scored 10031 out of a possible 430, using 0 turns.
You just went off my scale!!
-
-To achieve the next higher rating would be a neat trick!
-Congratulations!!
It may interest you to know that the Dungeon-Master himself has, to
my knowledge, never achieved this threshold in fewer than 330 turns.'
-To achieve the next higher rating, you need 9570 more points.
+To achieve the next higher rating would be a neat trick!
+Congratulations!!