Calculator Tools Calculator Tools
Create

Punctuation Mastery App

Jul 10, 2025

About this app

A fun and interactive web app for mastering punctuation skills through engaging exercises and quizzes.

Punctuation Mastery App Punctuation Mastery Submit

Related apps

Put this on your site

Source

                    <html>
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width,initial-scale=1">

<title>Punctuation Mastery App</title>
<meta name="description" content="A fun and interactive web app for mastering punctuation skills through engaging exercises and quizzes.">
<meta name="keywords" content="punctuation, grammar, educational, quizzes, mastery, interactive, learning">

<!-- Libraries -->
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.6.0/jquery.min.js" crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/css/bootstrap.min.css" crossorigin="anonymous">
<script src="https://cdn.jsdelivr.net/npm/bootstrap@5.3.3/dist/js/bootstrap.min.js" crossorigin="anonymous"></script>
<link rel="stylesheet" href="https://cdn.jsdelivr.net/npm/@fortawesome/fontawesome-free@6.6.0/css/fontawesome.min.css" crossorigin="anonymous">

<script type="text/javascript">
try {
// This will run when the DOM is ready.
document.addEventListener("DOMContentLoaded", function() {
const exercises = [
{ question: "What is missing here: I love pizza _____ its my favorite food", answer: "because", punctuated: "I love pizza because it's my favorite food." },
{ question: "Correct the punctuation: Lets eat Grandma", answer: ",", punctuated: "Let's eat, Grandma!" },
{ question: "What punctuation should be placed at the end: Where are you going", answer: "?", punctuated: "Where are you going?" }
];
let currentIndex = 0;
let score = 0;

function loadExercise() {
if (currentIndex < exercises.length) {
$("#question").text(exercises[currentIndex].question);
} else {
showResults();
}
}

function checkAnswer() {
const userAnswer = $("#answer").val().trim();
if (userAnswer.toLowerCase() === exercises[currentIndex].answer.toLowerCase()) {
score++;
alert("Correct! The full sentence is: " + exercises[currentIndex].punctuated);
} else {
alert("Incorrect! The correct word is: " + exercises[currentIndex].answer);
}
currentIndex++;
$("#answer").val('');
loadExercise();
}

function showResults() {
$("#main-container").html(`
<h2>Results</h2>
<p>Your score: ${score} out of ${exercises.length}</p>
<button class="btn btn-primary" onclick="location.reload()">Restart</button>
`);
}

$("#submit-button").click(checkAnswer);
loadExercise();
});

} catch (error) {
throw error;
}
</script>

<style>
body {
background: linear-gradient(90deg, #ffafbd, #ffc3a0);
color: #333;
font-family: 'Arial', sans-serif;
}
#main-container {
margin-top: 50px;
text-align: center;
}
#question {
font-size: 24px;
margin-bottom: 20px;
color: #ff6f61;
}
#answer {
font-size: 16px;
padding: 10px;
width: 80%;
border-radius: 5px;
border: 2px solid #ff6f61;
}
button {
margin-top: 20px;
}
</style>
</head>
<body>
<div id="main-container" class="container">
<h1>Punctuation Mastery</h1>
<div id="question"></div>
<input type="text" id="answer" placeholder="Your answer here..." />
<button id="submit-button" class="btn btn-success">Submit</button>
</div>
</body>
</html>