1answer.
Ask question
Login Signup
Ask question
All categories
  • English
  • Mathematics
  • Social Studies
  • Business
  • History
  • Health
  • Geography
  • Biology
  • Physics
  • Chemistry
  • Computers and Technology
  • Arts
  • World Languages
  • Spanish
  • French
  • German
  • Advanced Placement (AP)
  • SAT
  • Medicine
  • Law
  • Engineering
NARA [144]
3 years ago
12

Help, I'm a beginner in coding! I have to write a quiz. You don't have to get all fancy and stuff, since I'm a beginner lol. I w

ill give you brainliest if I your answer is helpful!!!
Your quiz program must have the following items:


1. It must start by asking the user what their name is and welcoming them to your quiz. It pays to be polite!

2. Set up a variable to keep score. It is up to you how to design the points system. Will you give them 10 points for a correct answer and 0 for an incorrect answer? Or perhaps you will be tough and take away points for an incorrect answer!

3. Ask your 10 quiz questions. If they get a question wrong, be sure to tell the user what the correct answer was. Then, adjust the score appropriately, depending on whether their answer was right or wrong.

4. At the end of the program, tell the user their score.


NOTE: For the 10 quiz questions, you can just write "put the question here" for me, and I will just add all 10.
Computers and Technology
1 answer:
Anuta_ua [19.1K]3 years ago
6 0

name = input("What's your name? ")

print("Hello " + name + ", welcome to my quiz!")

score = 0

di = {"qustion1": "answer1", "qustion2": "answer2", "qustion3": "answer3", "qustion4": "answer4", "qustion5": "answer5", "qustion6": "answer6",

     "qustion7": "answer7", "qustion8": "answer8", "qustion9": "answer9", "qustion10": "answer10"}

for x in di:

   user_answer = input(x+" ")

   if user_answer == di[x]:

       print("That's correct!")

       score += 1

   else:

       print("The correct answer is " + str(di[x]))

print("You got "+str(score)+" out of 10!")

I iterated through a dictionary with the questions and answers as the keys and values respectively. I hope this helps!

You might be interested in
In Microsoft word you can access the blank command from the mini toolbar
Softa [21]
Your answer would be:
<span>
In Microsoft Word you can access the </span><span>insert citation command from the mini toolbar.</span>
3 0
3 years ago
Which are the best examples of cost that should be considered when creating a project budget
sashaice [31]

Explanation:

how much the project will cost

5 0
3 years ago
Write the contributions of dr herman hollerith​
Ad libitum [116K]

He invented the tabulating machine. In 1890 U.S

5 0
3 years ago
Which feature is used to help identify the appropriate content for particular form fields?
Alika [10]

Answer:

The correct option is;

Content controls

Explanation:

Content controls are customizable controls that can be added to forms, templates and document that enable users to identify or preview the expected data that fills a given form field

Content controls can be in the form of instructional text that give users an idea of the expected format of the content of a given form field, such that the text disappears as soon as the user starts typing in their own text.

6 0
3 years ago
What is a list of data organized for easy access?
ozzi

Answer:

An Array

Explanation:

Array and Object is a good use for storing data and accessing it

6 0
2 years ago
Other questions:
  • Which Command Prompt commands in Windows is used for listing a computer connections to shared resources
    10·1 answer
  • Which of the following statements is NOT true about a mainframe computer?
    14·1 answer
  • What does TIA stand for?
    7·2 answers
  • If an M/M/1 queue in a server has task arrivals at a rate of 30 per second and serves at a rate of 50 per second, how many tasks
    10·1 answer
  • g Define memory hierarchy. A. The rate at which information can be transferred from one place to another. B. Ordering storage sy
    8·1 answer
  • Write a class called Person that has two data members - the person's name and age. It should have an init method that takes two
    12·1 answer
  • Code Problem 3 in Python 2.
    5·1 answer
  • Artificial intelligence (AI) and machine learning are especially important during which security information and event managemen
    8·1 answer
  • It would be at least two decades before some of
    12·1 answer
  • Your friend says, “I can’t ever watch a streaming movie without it pausing for long moments. It makes me crazy!” What might you
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!