from question_model import Question
from data import question_data
from quiz_brain import QuizBrain

question_bank = []

for q in question_data:
    question_text = q["question"]
    question_answer = q["correct_answer"]
    new_question = Question(question_text, question_answer)
    question_bank.append(new_question)

quizz = QuizBrain(question_bank)

while quizz.still_has_questions():
    quizz.next_question()


print("You have finished Quiz")
print(f"Your score is {quizz.score}")
