diff --git a/flask-quiz.html b/flask-quiz.html
new file mode 100644
index 0000000..ca130de
--- /dev/null
+++ b/flask-quiz.html
@@ -0,0 +1,62 @@
+
+
+
+
+
+
+ Flask QUIZ
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
\ No newline at end of file
diff --git a/index.html b/index.html
index d3bdc1a..812670c 100644
--- a/index.html
+++ b/index.html
@@ -43,6 +43,7 @@ Welcome to the Web Development Quiz
Django Quiz
DSA Quiz
DBMS Quiz
+ Flask Quiz
diff --git a/script.js b/script.js
index dca2bd2..7e04772 100644
--- a/script.js
+++ b/script.js
@@ -430,6 +430,60 @@ const dbmsQuestions = [
answer: "DISTINCT"
}
];
+//Flask Questions
+const flaskQuestions=[
+ {
+ question: "Flask is a ____ framework?",
+options: ["Frontend", "Backend", "Database", "Testing"],
+answer: "Backend"
+ },
+ {
+ question: "Which language is Flask built with?",
+ options: ["Python", "JavaScript", "Java", "C#"],
+ answer: "Python"
+ },
+ {
+ question: "Which template engine does Flask commonly use?",
+ options: ["EJS", "Jinja2", "Pug", "Handlebars"],
+ answer: "Jinja2"
+ },
+ {
+ question: "Flask follows which type of architecture?",
+ options: ["MVC", "MVVM", "MVP", "None"],
+ answer: "MVC"
+ },
+ {
+ question: "Which command is used to run a Flask application?",
+ options: ["python app.py", "flask run", "npm start", "node server.js"],
+ answer: "flask run"
+ },
+ {
+ question: "What file is typically used to define routes in a Flask app?",
+ options: ["routes.py", "app.py", "index.html", "server.js"],
+ answer: "app.py"
+ },
+ {
+ question: "Which method is used to handle form submission in Flask?",
+ options: ["GET", "POST", "FETCH", "PUT"],
+ answer: "POST"
+ },
+ {
+ question: "Which decorator is used to define a route in Flask?",
+ options: ["@route", "@app.route", "@get", "@flask.route"],
+ answer: "@app.route"
+ },
+ {
+ question: "How do you render an HTML template in Flask?",
+ options: ["render_template()", "show_html()", "display_page()", "render_page()"],
+ answer: "render_template()"
+ },
+ {
+ question: "Which object is used to get form data in Flask?",
+ options: ["request", "form", "data", "input"],
+ answer: "request"
+ }
+];
+
@@ -564,6 +618,10 @@ if (document.getElementById("html-questions")) {
questions = dsaQuestions;
sectionId = "dsa-questions";
}
+ else if (document.getElementById("flask-questions")) {
+ questions = flaskQuestions;
+ sectionId = "flask-questions";
+}
// Render questions and attach event listeners only if a valid section is found
if (sectionId) {
diff --git a/src/data/flask.json b/src/data/flask.json
new file mode 100644
index 0000000..7f1d53c
--- /dev/null
+++ b/src/data/flask.json
@@ -0,0 +1,54 @@
+{
+"questions": [
+ {
+ "question": "Flask is a ____ framework?",
+ "options": ["Frontend", "Backend", "Database", "Testing"],
+ "answer": "Backend"
+ },
+ {
+ "question": "Which language is Flask built with?",
+ " options": ["Python", "JavaScript", "Java", "C#"],
+ "answer": "Python"
+ },
+ {
+ "question": "Which template engine does Flask commonly use?",
+ "options": ["EJS", "Jinja2", "Pug", "Handlebars"],
+ "answer": "Jinja2"
+ },
+ {
+ "question": "Flask follows which type of architecture?",
+ "options": ["MVC", "MVVM", "MVP", "None"],
+ "answer": "MVC"
+ },
+ {
+ "question": "Which command is used to run a Flask application?",
+ "options": ["python app.py", "flask run", "npm start", "node server.js"],
+ "answer": "flask run"
+ },
+ {
+ "question": "What file is typically used to define routes in a Flask app?",
+ "options": ["routes.py", "app.py", "index.html", "server.js"],
+ "answer": "app.py"
+ },
+ {
+ "question": "Which method is used to handle form submission in Flask?",
+ "options": ["GET", "POST", "FETCH", "PUT"],
+ "answer": "POST"
+ },
+ {
+ "question": "Which decorator is used to define a route in Flask?",
+ "options": ["@route", "@app.route", "@get", "@flask.route"],
+ "answer": "@app.route"
+ },
+ {
+ "question": "How do you render an HTML template in Flask?",
+ "options": ["render_template()", "show_html()", "display_page()", "render_page()"],
+ "answer": "render_template()"
+ },
+ {
+ "question": "Which object is used to get form data in Flask?",
+ "options": ["request", "form", "data", "input"],
+ "answer": "request"
+ }
+ ]
+}
\ No newline at end of file
diff --git a/src/index.html b/src/index.html
index c88404b..c68ef40 100644
--- a/src/index.html
+++ b/src/index.html
@@ -27,6 +27,7 @@ Select a Quiz Topic
DSA
Django
C(Programming)
+ Flask