Download as docx, pdf, or txt
Download as docx, pdf, or txt
You are on page 1of 5

Republic of the Philippines

NORTH EASTERN MINDANAO STATE UNIVERSITY


Poblacion, Lianga, Surigao del Sur
Bachelor of Science in Computer Science

INTERMEDIATE PROGRAMMING - PYTHON

FINAL PROJECT

QUIZ GAME

Submitted by:
Nicolo Jhon D. Ricafort
Hazel Jhane R. Pajaron
BSCS 1B Students

Submitted to:

Julia kate C. Villamon


Instructor
TABLE OF CONTENTS

Title Page ……………………………………………………………………….……………………… i

Table of Contents …………………………………………………………………………………. ii

Statement of the Problem ……………………………….………………………………… 1

Flowchart ………………………………….………….…………………………….…………………. 2

Algorithm ….…………………………………………….………….………………………………… . 2

Code …………………………………….………………………………...………………………………. 4

Output ……………………….………………………………………….………………………………… 4
STATEMENT OF THE PROBLEM

Create a program that administers a quiz to user, testing their knowledge of the national
symbols of the Philippines. The program should display a series of questions, each with
multiple-choice options, and keep track of the user’s answers. At the end of the quiz, the
program should display the user’s score, indicating how many questions they answered
correctly.

FLOWCHART

START Initialize answer =


{} and score = 0

Loop questions

Display question
and options

End Get answer

Display final Store answer in


score & message dictionary

End loop if
Increment score all question
is done No

Yes
Yes

Compare user’s
Match answer with
? correct answer
No
ALGORITHM

1. Start

2. Initialize an empty dictionary ‘answers’ to store user answer.

3. Initialize a variable ‘score’ to 0 to keep track of the user’s answers.

4. Loop through each question in the ‘question’ list:


a. Display the question and its options to the user.
b. Get the user’s anser (inout) an store it in the ‘answer’ dictionary.
5. Loop through each question in the ‘question’ list again:
a. Compare the user’s answer with the correct answer.
b. If the answers match, increment the ‘score’ variable.

6. Display the usser’s final score to the user.

7. End the quiz.


CODE
OUTPUT

You might also like