No, I use a different function:
enum difficulty(easy, moderate, hard, impossible);
...
int do_exam(difficulty level)
{
struct my_knowledge *a;
if ((a=(int*)malloc(sizeof(my_memory)*sizeof(time_studied)))!=NULL)
{
if (level<=moderate) return 1;
else return 0;
}
else return 0;
while (thinking_about_cheating) knock_himself_on_the_head_and_continue=1;
} |