|
@ -66,6 +66,10 @@ void e_usr_answr(char question[][100], char ans[], int initial, int end){ |
|
|
bool ans1 = e_true_false(user_answer); |
|
|
bool ans1 = e_true_false(user_answer); |
|
|
if(ans1 == ans[i]) { |
|
|
if(ans1 == ans[i]) { |
|
|
score++; |
|
|
score++; |
|
|
|
|
|
track_r2_score++; |
|
|
|
|
|
if(track_r2_score >= 2) { |
|
|
|
|
|
track_r2_score = 0; |
|
|
|
|
|
} |
|
|
correct(score); |
|
|
correct(score); |
|
|
} else{ |
|
|
} else{ |
|
|
wrong(score); |
|
|
wrong(score); |
|
@ -76,17 +80,25 @@ void e_usr_answr(char question[][100], char ans[], int initial, int end){ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
void e_t_f_printQuestions(char askquestion[][100],char answers[]) { |
|
|
void e_t_f_printQuestions(char askquestion[][100],char answers[]) { |
|
|
|
|
|
|
|
|
|
|
|
int track_rounds = 0; |
|
|
|
|
|
while(track_rounds < 1){ |
|
|
printf("\t\t---------------------------Round1-----------------------------\n"); |
|
|
printf("\t\t---------------------------Round1-----------------------------\n"); |
|
|
printf("\t\t >>In this round you will be presented with 3 questions.<<\n"); |
|
|
printf("\t\t >>In this round you will be presented with 3 questions.<<\n"); |
|
|
printf("\t\t--------------------------------------------------------------\n\n"); |
|
|
printf("\t\t--------------------------------------------------------------\n\n"); |
|
|
int init = 0, end = 3; |
|
|
int init = 0, end = 3; |
|
|
e_usr_answr(askquestion,answers, init, end); |
|
|
e_usr_answr(askquestion,answers, init, end); |
|
|
|
|
|
|
|
|
|
|
|
if(score < 2) { |
|
|
|
|
|
break; |
|
|
|
|
|
} else { |
|
|
printf("\t\t---------------------------Round2-----------------------------\n"); |
|
|
printf("\t\t---------------------------Round2-----------------------------\n"); |
|
|
printf("\t\t >>In this round you will be presented with 2 questions.<<\n"); |
|
|
printf("\t\t >>In this round you will be presented with 2 questions.<<\n"); |
|
|
printf("\t\t--------------------------------------------------------------\n\n"); |
|
|
printf("\t\t--------------------------------------------------------------\n\n"); |
|
|
init = 3, end = 5; |
|
|
init = 3, end = 5; |
|
|
e_usr_answr(askquestion,answers, init, end); |
|
|
e_usr_answr(askquestion,answers, init, end); |
|
|
|
|
|
} |
|
|
|
|
|
track_rounds++; |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
@ -180,7 +192,11 @@ void e_printout_r3 (char question[][100], char answers[][100]) { |
|
|
void e_smart_brain() { |
|
|
void e_smart_brain() { |
|
|
e_display_instruction(); |
|
|
e_display_instruction(); |
|
|
e_ask_questions(); |
|
|
e_ask_questions(); |
|
|
|
|
|
if(score >=4 && track_r2_score ==0) { |
|
|
e_questions_r3(); |
|
|
e_questions_r3(); |
|
|
|
|
|
} |
|
|
|
|
|
score = 0; |
|
|
|
|
|
track_r2_score = 0; |
|
|
} |
|
|
} |
|
|
//-------smart_brain_quiz_end------------ |
|
|
//-------smart_brain_quiz_end------------ |
|
|
|
|
|
|
|
|