X-Git-Url: https://git.cworth.org/git?p=mnemon;a=blobdiff_plain;f=mnemon.c;h=56a518d8ed752e63c06023d1c884474089346b76;hp=87e1fd08b6530089cca9d12270405d0b1569d1c7;hb=31b5189a8145b2b514d69165997e2e443f52dd52;hpb=4afda67e5f06fd1a8e77459355a325a42cd2d594 diff --git a/mnemon.c b/mnemon.c index 87e1fd0..56a518d 100644 --- a/mnemon.c +++ b/mnemon.c @@ -1041,6 +1041,7 @@ mnemon_handle_command (mnemon_t *mnemon, const char *arg; int len; switch (command[0]) { + /* 'h' for histogram */ case 'h': { char *category = NULL; @@ -1059,6 +1060,12 @@ mnemon_handle_command (mnemon_t *mnemon, mnemon_print_histogram (mnemon, category, length); } break; + /* 'r' for repeat */ + case 'r': + { + /* Nothing necessary for repeating. */ + } + break; default: printf ("Unknown command: %s\n", command); break; @@ -1289,6 +1296,13 @@ mnemon_do_challenges (mnemon_t *mnemon) (start.tv_sec + start.tv_usec / 1e6), category->time_limit); free (response); + + /* Replay audio challenges for reinforcement. */ + if (category->challenge_type == CHALLENGE_TYPE_AUDIO) { + mnemon_show_challenge (mnemon, category->challenge_type, + item->challenge); + sleep (1); + } } while (mnemon->to_introduce || mnemon->unlearned || mnemon->to_master > 0);