Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

Write an interactive quiz. It should ask the user three multiple-choice or true/false questions about anything. It must keep track of how many they get

Write an interactive quiz. It should ask the user three multiple-choice or true/false questions about anything.

It must keep track of how many they get right, and print out a score at the end.

Your output should look like:

Are you ready for a quiz? X 
Okay, here it comes! Q1) What is the capital of Alaska? 1)Melbourne 2)Anchorage 3)Juneau 

> 3

Thats right! 
Q2) Can you store the value cat in a variable of type int? 
1)Yes 2)No 
> 1 
Sorry, cat is a string. ints can only store numbers. 
Q3) What is the result of 9+6/3? 
1)5 2)11 3)15/3 
> 2 
Thats correct! 
 Overall, you got 2 out of 3 correct. Thanks for playing! 

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image

Step: 3

blur-text-image

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Flash XML Applications Use AS2 And AS3 To Create Photo Galleries Menus And Databases

Authors: Joachim Schnier

1st Edition

0240809173, 978-0240809175

More Books

Students also viewed these Databases questions

Question

Write Hund's rule?

Answered: 1 week ago

Question

How do Data Types perform data validation?

Answered: 1 week ago

Question

How does Referential Integrity work?

Answered: 1 week ago