Quiz Game Script!27
Quiz Game Script!27
local questions = {
{question = "What is the capital of France?", answer = "Paris"},
{question = "What is 5 + 7?", answer = "12"},
{question = "What planet is known as the Red Planet?", answer = "Mars"},
{question = "What is the largest ocean on Earth?", answer = "Pacific"},
{question = "Who wrote 'Romeo and Juliet'?", answer = "Shakespeare"},
{question = "What gas do plants absorb from the atmosphere?", answer = "Carbon
Dioxide"},
{question = "What is the square root of 64?", answer = "8"},
}
-- Player score
local score = 0
local totalQuestions = #questions
local askedQuestions = {}
print(selectedQuestion.question)
local playerAnswer = io.read() -- Get player’s input