0% found this document useful (0 votes)
9 views

QuizAppDoc

The document outlines the development of a Quiz App aimed at providing an interactive and educational platform for users to test their knowledge across various categories. Key features include a responsive design, multiple-choice functionality, real-time scoring, and a countdown timer, all built using HTML, CSS, and JavaScript. The development process follows the Software Development Life Cycle (SDLC) and includes thorough testing phases to ensure usability and performance.

Uploaded by

amargs4774
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
9 views

QuizAppDoc

The document outlines the development of a Quiz App aimed at providing an interactive and educational platform for users to test their knowledge across various categories. Key features include a responsive design, multiple-choice functionality, real-time scoring, and a countdown timer, all built using HTML, CSS, and JavaScript. The development process follows the Software Development Life Cycle (SDLC) and includes thorough testing phases to ensure usability and performance.

Uploaded by

amargs4774
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 34

Introduction

Quizzes are widely used as an educational tool in classrooms, e-learning


platforms, and competitive exams. The purpose of creating a Quiz App is to
deliver an engaging and dynamic platform where users can test their
knowledge across multiple categories.
The Quiz App helps users engage in self-assessment and improves memory
retention through quick recall of facts. It is also helpful for educators to
monitor student progress through frequent testing.
The user interface simulates the behavior of real-time online test portals
that many competitive exams and recruitment assessments follow. This
gives users a familiar and effective test-taking experience.

Key characteristics include:


• Accessibility on desktop and mobile devices
• Lightweight front-end interface with minimal load time
• Interactive UI with timed tests and score display

The Quiz App provides a strong base for future enhancements, including
dynamic question loading from external sources or APIs, result analytics,
user logins, and question difficulty scaling.
Objective

The objective of the project is to develop a robust and educationally


enriching quiz platform that enhances the learning experience through
interactivity and accessibility. More specifically, the key goals are:

Create an Interactive Front-End Quiz Application: Design an engaging web


interface using HTML, CSS, and JavaScript that captures the essence of a
test-taking environment.

Deliver Multiple-Choice Question Functionality: Each question should have


predefined options, among which the user selects one answer. The system
should validate this choice and provide real-time feedback.

Implement a Real-Time Timer and Score Tracking System: A countdown


mechanism should challenge the user to complete the quiz within a set
time frame while tracking correct answers and total score.

Make the App Accessible and Responsive Across Devices: The app should
be built using responsive design techniques, ensuring it works well on
desktops, tablets, and smartphones.

Build a Clean, Modern UI/UX That Improves Learning Experience: Use


intuitive layouts, readable fonts, and visual feedback to make navigation
and quiz participation enjoyable.

This objective not only helps enhance technical skills like DOM
manipulation and event handling but also introduces essential UI/UX
design practices. In the broader academic context, the app serves as a
model for building scalable, front-end based learning tools.
System Requirements

For the development and proper execution of the Quiz App, the following
system requirements are recommended:

Hardware Requirements:
• RAM: Minimum 2 GB (4 GB or higher recommended for better
performance)
• Processor: Dual Core or above (Intel i3/i5 or equivalent)
• Storage: At least 500 MB free space
• Display: Minimum 1024x768 screen resolution

These basic hardware components ensure that the browser and editor
used for developing the Quiz App run smoothly without lags.

Software Requirements:
• Operating System: Windows, macOS, or Linux
• Browser: Google Chrome (preferred), Mozilla Firefox, Microsoft Edge
• Code Editor: Visual Studio Code (recommended), Sublime Text,
Atom
• Version Control: Git (for tracking versions and collaboration)
Technologies Used

The Quiz App was developed using a lightweight front-end technology stack
that provides high performance, easy deployment, and responsive design.
Below are the core technologies used:

1. HTML5 (HyperText Markup Language)


HTML was used to define the structure of the quiz application. It includes
all elements such as headings, buttons, question containers, and layout
divisions.
• Creates the skeleton of the quiz
• Supports semantic tags for accessibility

2. CSS3 (Cascading Style Sheets)


CSS is responsible for styling and enhancing the visual appeal of the quiz. It
ensures that the app looks clean and is pleasant to use.
• Responsive design using flexbox and media queries
• Animation effects on button hover
• Light and dark theme styling (if extended)

3. JavaScript (ES6)
JavaScript powers the interactivity of the quiz. It is used to handle logic,
including question shuffling, answer validation, score calculation, and
countdown timer.
• DOM manipulation for dynamic content updates
• Event listeners for user interaction
• JSON-like data structure to manage questions
Features

The Quiz App includes a wide range of essential features designed to


ensure interactivity, usability, and effective learning outcomes. The major
features include:

1. Start Quiz Functionality


• The quiz begins on clicking the "Start Quiz" button.
• Initializes the question counter and timer.
2. Dynamic Question Rendering
• Questions are displayed one at a time from a predefined array.
• Each question is dynamically rendered with options.
3. Answer Validation and Scoring
• Clicked answers are compared against the correct answer.
• Immediate feedback is provided and the score is updated.
4. Countdown Timer
• Timer starts when the quiz begins.
• Decreases by 1 second and displayed on-screen.
• Automatically ends the quiz when time runs out.
5. Responsive Design
• The quiz is fully responsive across desktops, tablets, and mobile
devices.
6. Final Score Summary
• Once the quiz ends, the score is displayed.
• Shows correct answers and percentage achieved.
Software Development Life Cycle
(SDLC)

The development of the Quiz App followed the Software Development Life
Cycle (SDLC) model to ensure systematic planning, execution, and testing
of the project. SDLC is a structured process used by developers to create
high-quality software in a cost-effective and time-efficient way.
Stages of SDLC:
1. Requirement Analysis:
Understanding the purpose of the app, end-user expectations, and
educational needs. The main requirement was to build a client-side quiz
system using HTML, CSS, and JavaScript.
2. System Design:
Planning the architecture, defining UI elements, quiz logic structure, and
navigation flow.
3. Implementation (Coding):
Development of the HTML structure, CSS styling, and JavaScript
functionality.
4. Testing:
Verifying correct output, checking timer logic, score accuracy, and
responsiveness on different devices.
5. Deployment:
Hosting the project for local or public access using live server tools or
GitHub Pages.
6. Maintenance:
Bug fixes, updating questions, enhancing UI or adding features based on
user feedback.
Project Design

The design of the Quiz App includes both visual interface planning and
logical component structuring. The app layout was sketched initially to
understand the flow between components like welcome screen, question
display, timer, and result summary.

The UI is clean and minimal to ensure ease of use, focusing user attention
on content. Colors, fonts, and spacing were carefully chosen to maintain
accessibility and readability across devices.
Project Structure

The Quiz App follows a simple project structure that ensures modularity
and ease of understanding. It is divided into three core files:

1. index.html
• The main HTML file.
• Contains the basic structure of the quiz interface including
containers for title, questions, buttons, and results.

2. style.css
• Styles the quiz interface with colors, fonts, alignment, spacing, and
responsiveness.
• Includes hover effects, media queries, and visual feedback styling.

3. script.js
• Contains the complete quiz logic.
• Handles timer, dynamic question loading, answer validation, score
tracking, and result display.

This clean file structure helps in easily maintaining and scaling the project
in the future.
HTML Structure

The HTML file is the skeleton of the app, containing all elements such as
buttons, text, questions, and options.

HTML Code Structure :

<div class="quiz-container">
<h1>Quiz App</h1>
<div id="question-container">
<p>Question goes here</p>
<div id="options-container">
<button class="option">Option 1</button>
<button class="option">Option 2</button>
<button class="option">Option 3</button>
<button class="option">Option 4</button>
</div>
</div>
<div id="score-container">Score: 0</div>
<button id="start-btn">Start Quiz</button>
</div>
CSS Styling

The CSS is designed to make the app visually appealing and responsive.
Here’s an example of styling for the quiz container:

CSS Code Styling:

.quiz-container {
max-width: 800px;
margin: 20px auto;
padding: 20px;
background-color: #fff;
border-radius: 8px;
box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
}

button {
background-color: #007bff;
color: #fff;
padding: 10px 20px;
border: none;
cursor: pointer;
}
JavaScript Functionality

JavaScript powers the app’s interactivity. Here's an example of how the quiz
logic is handled:

JavaScript :

let score = 0;
const startButton = document.getElementById('start-btn');
startButton.addEventListener('click', function() {
startQuiz();
});

function startQuiz() {
// Logic to start the quiz and display the first question
}
Code Explanation

In this section, we dive deeper into the core JavaScript code used in the
Quiz App. The logic is divided into smaller functions to manage different
aspects of the quiz, such as starting the quiz, displaying questions,
handling user input, and calculating the score.
Starting the Quiz
When the user clicks the "Start Quiz" button, the startQuiz function is
triggered, which sets the initial question and starts the timer.

let score = 0;
let currentQuestionIndex = 0;
let timer = 60; // 1 minute timer

const startButton = document.getElementById('start-btn');


startButton.addEventListener('click', function() {
startQuiz();
});

function startQuiz() {
currentQuestionIndex = 0; // Reset the index to start from the first
question
score = 0; // Reset score
timer = 60; // Reset the timer
startTimer(); // Start the countdown timer
loadQuestion(currentQuestionIndex); // Load the first question
}
Loading Questions
The loadQuestion function dynamically loads questions and their
respective options onto the screen. The questions are stored in an array,
and each question is displayed based on the current index.

const questions = [
{
question: "What is the capital of France?",
options: ["Berlin", "Madrid", "Paris", "Rome"],
correctAnswer: "Paris"
},
{
question: "Which planet is known as the Red Planet?",
options: ["Earth", "Mars", "Jupiter", "Saturn"],
correctAnswer: "Mars"
},
// Add more questions here
];

function loadQuestion(index) {
const questionContainer = document.getElementById('question-
container');
const question = questions[index];

questionContainer.innerHTML = `
<p>${question.question}</p>
<div id="options-container">
${question.options.map((option, i) => `
<button class="option"
onclick="checkAnswer('${option}')">${option}</button>
`).join('')}
</div>
`;
}

Checking Answers
When a user selects an option, the checkAnswer function validates the
answer and updates the score.

function checkAnswer(selectedOption) {
const currentQuestion = questions[currentQuestionIndex];
if (selectedOption === currentQuestion.correctAnswer) {
score++;
}
currentQuestionIndex++;
if (currentQuestionIndex < questions.length) {
loadQuestion(currentQuestionIndex); // Load next question
} else {
endQuiz(); // End the quiz if all questions are answered
}
}
Timer
The timer is a countdown that starts as soon as the quiz begins. If the time
runs out, the quiz ends automatically.

function startTimer() {
const timerInterval = setInterval(function() {
timer--;
document.getElementById('timer').innerText = `Time left: ${timer}s`;
if (timer <= 0) {
clearInterval(timerInterval);
endQuiz(); // End the quiz when time runs out
}
}, 1000);
}

Ending the Quiz


At the end of the quiz, the user’s score is displayed, and the app offers an
option to restart the quiz.

function endQuiz() {
document.getElementById('quiz-container').innerHTML = `
<h2>Quiz Over</h2>
<p>Your score is: ${score}/${questions.length}</p>
<button onclick="startQuiz()">Restart Quiz</button>
`;
}
Testing and Validation

Testing and validation are crucial steps in the software development


process, as they ensure that the Quiz App functions as expected, provides
a smooth user experience, and is free of major bugs or errors. This section
covers the testing approach employed to verify that the app is stable,
secure, and meets the specified requirements. The testing process is
divided into three primary categories: Unit Tests, Integration Tests, and
User Testing.

1. Unit Tests
Unit tests are designed to test individual features and functions of the app
in isolation. Each function or feature is tested to ensure it performs as
expected under different conditions. Unit testing helps catch issues early in
the development process and ensures that the smallest parts of the app
are working correctly.
Key Unit Tests for the Quiz App:
• Answer Selection: Ensuring that the app correctly registers user-
selected answers. Test cases would verify that the selected answer is
stored accurately and that only one option can be selected at a time.
• Score Calculation: Testing the algorithm that calculates the user’s
score based on the correct answers. Different scenarios (e.g., all
correct answers, no correct answers, some correct answers) are
tested to verify that the score is calculated properly.
• Timer Functionality: The countdown timer is tested to ensure it
starts when the quiz begins, counts down correctly, and stops when
the quiz ends. Edge cases like fast navigation or timer manipulation
are also tested.
• Input Validation: Ensuring that user inputs are validated before
submission (e.g., checking for empty answers or invalid input).
Tools Used:
• Jest: A JavaScript testing framework used for testing individual
components and functions.
• Mocha: Another testing framework used for unit testing the app’s
backend code (if applicable).

2. Integration Tests
Integration tests ensure that various components of the app work together
seamlessly. They test how different features interact with each other and
ensure that the data flows correctly between the frontend, backend, and
database.
Key Integration Tests for the Quiz App:
• User Authentication and Session Management: Testing how the
login and user session system interacts with the frontend and
backend. The app should properly store the user’s session and allow
for login/logout functionality.
• Question Retrieval and Display: Ensuring that quiz questions are
properly retrieved from the database (or API) and displayed correctly
to the user. This tests the integration of the frontend UI with the
backend database or API.
• Score Submission: Ensuring that once the quiz is completed, the
score is submitted to the database and saved correctly. This tests the
flow of data from the frontend quiz interface to the backend
database.
• Timer and Question Navigation: Testing the interaction between the
quiz timer, the question navigation, and the final score submission.
The timer should pause when the user navigates between questions
and resume properly when they return.
Tools Used:
• Cypress: A popular end-to-end testing tool used to automate
integration testing of web apps.
• Postman: Used to test API endpoints for retrieving questions and
submitting scores.

3. User Testing
User testing involves gathering feedback from actual users to validate the
app's usability, identify areas of improvement, and ensure that the app
provides a satisfying user experience. This testing is typically done after
unit and integration tests are completed.
Key Areas Tested in User Testing:
• Usability: Users are asked to complete a quiz and provide feedback
on how easy and intuitive the app is. This helps identify any confusing
interfaces or difficult navigation.
• UI/UX Design: Ensuring that the layout and visual elements of the
app are appealing and intuitive. Users provide feedback on elements
such as color schemes, button placement, and font sizes.
• Quiz Difficulty: Users test the difficulty of the questions, ensuring
that the app has an appropriate mix of question difficulty. Feedback
is gathered on whether the quizzes are too easy, too difficult, or just
right.
• Mobile Responsiveness: Testing how well the app works on different
screen sizes (e.g., smartphones, tablets, and desktops). Users
provide feedback on how the app functions and looks on smaller
devices.
• Overall Experience: Gathering feedback on the overall experience of
using the app, including speed, performance, and any issues that
arose during usage.
Methods Used:
• Beta Testing: A small group of target users is given access to the app
before it is released to the public. They are asked to complete various
tasks and provide feedback.
• Surveys and Feedback Forms: After completing the quiz, users are
prompted to fill out a survey or feedback form to collect their
thoughts on the app’s functionality and design.
• User Interviews: Conducting interviews with a small group of users
to gather in-depth insights about their experience with the app.

Bug Tracking and Issue Resolution


Any bugs or issues discovered during the testing process are logged and
tracked using a bug-tracking system. Developers work on resolving these
issues before the app is released to the public. Some common bugs that
were addressed during testing include:
• UI Glitches: Instances where the app layout was distorted or
elements didn’t align properly on different devices.
• Functionality Bugs: Issues where the app didn’t function as
expected, such as the timer not resetting properly or answers not
being recorded.
• Performance Issues: Slow loading times or unresponsiveness under
heavy use.
Conclusion

The Quiz App has been developed to provide an engaging and interactive
platform for users to test their knowledge across various categories. With
the integration of multiple features such as dynamic quizzes, real-time
scoring, a user-friendly interface, and mobile responsiveness, the app
offers a seamless experience for both beginners and enthusiasts.
Through a rigorous development process, which included extensive testing
and validation, the app has been optimized for both functionality and
usability. The features were designed with simplicity in mind, ensuring that
users can easily navigate through quizzes, track their progress, and improve
their knowledge over time. Additionally, the app is built with scalability in
mind, enabling future enhancements and new features.
Some key takeaways include:
• User-Centered Design: Feedback gathered from user testing
ensured that the app meets the needs of its audience and provides a
satisfying experience.
• Quality Assurance: Extensive unit, integration, and user testing have
been conducted to ensure a bug-free, reliable app.
• Future Potential: With the potential to expand into new categories,
multiplayer modes, and mobile app development, the Quiz App is
well-positioned for continued growth and improvement.
In conclusion, the app is not just a tool for quizzing but also an educational
resource aimed at helping users enhance their general knowledge. Moving
forward, additional features and updates will further refine and expand the
app, creating an even more engaging and useful platform.
References

The following references were used throughout the development of the


Quiz App:

1. MDN Web Docs – Comprehensive resources for learning about web


technologies, including HTML, CSS, and JavaScript.
o URL: https://developer.mozilla.org

2. Stack Overflow – A community-driven platform for resolving coding


issues and getting expert advice.
o URL: https://stackoverflow.com

3. Cypress Documentation – Official documentation for Cypress, used


for integration and end-to-end testing.
o URL: https://www.cypress.io

4. Jest Documentation – Official testing framework documentation


used for unit testing in the Quiz App.
o URL: https://jestjs.io

5. Postman – A tool used for API testing to ensure correct data flow and
submission in the app.
o URL: https://www.postman.com
6. Bootstrap – Frontend framework used for responsive design and UI
elements.
o URL: https://getbootstrap.com
7. Firebase Documentation – Documentation for Firebase, used for
user authentication and database management.
o URL: https://firebase.google.com
8. W3Schools – A free web development resource, useful for
referencing HTML, CSS, and JavaScript tutorials.
o URL: https://www.w3schools.com
9. GitHub Repositories – Various open-source repositories used for
reference and inspiration, including quiz-related implementations.
o URL: https://github.com
10. UX Design Resources – Various articles and case studies on
user experience design, especially for educational apps and
websites.
o URL: https://www.smashingmagazine.com
These resources provided valuable insights and tools that helped shape
the development of the app, ensuring that it adheres to best practices and
meets high-quality standards.
Project Source Code :

Index.html :

<!DOCTYPE html>
<html>
<head>
<title>Quiz App</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>
<body>
<div class="quiz-container">
<h1>Quiz App</h1>
<div id="question-container">
<p id="question-text"></p>
<div id="answer-buttons"></div>
</div>
<div id="controls-container">
<button id="start-button">Start Quiz</button>
<div id="timer-container">
<span id="timer-text">Time Left: <span id="timer">0</span></span>
</div>
</div>
</div>
<script src="script.js"></script>
</body>
</html>
Script.js :

// Define an array of quiz questions

const quizQuestions = [

question: "What is the capital of France?",

options: ["Paris", "London", "Berlin", "Rome"],

correctAnswer: "Paris"

},

question: "Which planet is known as the Red Planet?",

options: ["Venus", "Mars", "Jupiter", "Saturn"],

correctAnswer: "Mars"

},

question: "What is the chemical symbol for gold?",

options: ["Au", "Ag", "Cu", "Fe"],

correctAnswer: "Au"

},

question: "What does ETI stand for in project management?",

options: ["Estimated Time to Implement", "Expected Task Interval", "Effort Time


Indicator", "Execution Time Index"],

correctAnswer: "Estimated Time to Implement"

},

question: "Who wrote 'Romeo and Juliet'?",

options: ["William Shakespeare", "Charles Dickens", "Mark Twain", "Jane Austen"],

correctAnswer: "William Shakespeare"

},

{
question: "What is the largest ocean on Earth?",

options: ["Atlantic Ocean", "Indian Ocean", "Arctic Ocean", "Pacific Ocean"],

correctAnswer: "Pacific Ocean"

},

question: "What is the square root of 64?",

options: ["6", "7", "8", "9"],

correctAnswer: "8"

},

question: "Which country is known as the Land of the Rising Sun?",

options: ["China", "Japan", "South Korea", "Thailand"],

correctAnswer: "Japan"

},

question: "What is the boiling point of water in Celsius?",

options: ["90°C", "100°C", "110°C", "120°C"],

correctAnswer: "100°C"

},

question: "Who painted the Mona Lisa?",

options: ["Leonardo da Vinci", "Vincent van Gogh", "Pablo Picasso", "Claude Monet"],

correctAnswer: "Leonardo da Vinci"

},

question: "What is the smallest prime number?",

options: ["0", "1", "2", "3"],

correctAnswer: "2"

},

question: "What is the capital of Australia?",


options: ["Sydney", "Melbourne", "Canberra", "Brisbane"],

correctAnswer: "Canberra"

},

question: "Which gas do plants primarily use for photosynthesis?",

options: ["Oxygen", "Carbon Dioxide", "Nitrogen", "Hydrogen"],

correctAnswer: "Carbon Dioxide"

},

question: "What is the largest planet in our solar system?",

options: ["Earth", "Mars", "Jupiter", "Saturn"],

correctAnswer: "Jupiter"

},

question: "What is the freezing point of water in Fahrenheit?",

options: ["0°F", "32°F", "100°F", "212°F"],

correctAnswer: "32°F"

},

question: "Who discovered gravity?",

options: ["Albert Einstein", "Isaac Newton", "Galileo Galilei", "Nikola Tesla"],

correctAnswer: "Isaac Newton"

},

question: "What is the capital of Italy?",

options: ["Venice", "Rome", "Florence", "Milan"],

correctAnswer: "Rome"

},

question: "Which element has the atomic number 1?",

options: ["Oxygen", "Hydrogen", "Helium", "Carbon"],


correctAnswer: "Hydrogen"

},

question: "What is the name of the longest river in the world?",

options: ["Amazon River", "Nile River", "Yangtze River", "Mississippi River"],

correctAnswer: "Nile River"

},

question: "Which programming language is known as the language of the web?",

options: ["Python", "JavaScript", "C++", "Java"],

correctAnswer: "JavaScript"

];

// Variables to track quiz state

let currentQuestionIndex = 0;

let score = 0;

let timeLeft = 30;

let timerInterval;

// Function to start the quiz

function startQuiz() {

// Hide the start button and display the first question

document.getElementById("start-button").style.display = "none";

displayQuestion();

startTimer();

// Function to display a question and its options

function displayQuestion() {

const currentQuestion = quizQuestions[currentQuestionIndex];


const questionText = document.getElementById("question-text");

const answerButtons = document.getElementById("answer-buttons");

// Clear previous question and answer options

questionText.innerHTML = "";

answerButtons.innerHTML = "";

// Display the current question

questionText.innerHTML = currentQuestion.question;

// Create answer buttons for each option

currentQuestion.options.forEach(option => {

const button = document.createElement("button");

button.innerText = option;

button.classList.add("answer-button");

answerButtons.appendChild(button);

// Add click event listener to check the answer

button.addEventListener("click", function() {

checkAnswer(option);

});

});

// Function to check the selected answer

function checkAnswer(selectedOption) {

const currentQuestion = quizQuestions[currentQuestionIndex];

// Check if the selected answer is correct

if (selectedOption === currentQuestion.correctAnswer) {

score++;
}

// Move to the next question or end the quiz if all questions are answered

currentQuestionIndex++;

if (currentQuestionIndex < quizQuestions.length) {

displayQuestion();

} else {

endQuiz();

// Function to start the timer

function startTimer() {

timerInterval = setInterval(function() {

timeLeft--;

// Update the timer text

document.getElementById("timer").textContent = timeLeft;

// End the quiz if time runs out

if (timeLeft <= 0) {

endQuiz();

}, 1000);

// Function to end the quiz

function endQuiz() {

// Stop the timer

clearInterval(timerInterval);
// Calculate the score percentage

const scorePercentage = (score / quizQuestions.length) * 100;

// Display the final score

const questionContainer = document.getElementById("question-container");

questionContainer.innerHTML = `

<h2>Quiz Completed!</h2>

<p>Your Score: ${score} out of ${quizQuestions.length}</p>

<p>Score Percentage: ${scorePercentage}%</p>

`;

// Add event listener to start the quiz when the start button is clicked

document.getElementById("start-button").addEventListener("click", startQuiz);
Style.css :

body {

background-color: #f2f2f2;

font-family: Arial, sans-serif;

display: flex;

justify-content: center;

align-items: center;

height: 100vh;

.quiz-container {

max-width: 500px;

background-color: #fff;

border-radius: 10px;

padding: 20px;

box-shadow: 0 0 10px rgba(0, 0, 0, 0.2);

h1 {

text-align: center;

#question-container {

margin-bottom: 20px;

#question-text {

font-size: 18px;

margin-bottom: 10px;

}
#answer-buttons {

display: grid;

grid-template-columns: repeat(2, 1fr);

grid-gap: 10px;

button {

height: 40px;

font-size: 16px;

background-color: #eaeaea;

border: none;

border-radius: 5px;

cursor: pointer;

button:hover {

background-color: #d2d2d2;

#controls-container {

display: flex;

justify-content: space-between;

align-items: center;

#timer-container {

display: flex;

align-items: center;

}
#timer-text {

font-size: 14px;

#timer {

font-weight: bold;

margin-left: 5px;

}
Developer's Note :

This project was a great opportunity to apply and enhance my development


skills. Building the Quiz App helped me understand the practical aspects of
frontend design, user interaction, and project structuring. I look forward to
improving it further with new features and better performance in future
iterations.

You might also like