Design a program that gives simple math quizzes. The program should display two random numbers that are to be added, such as: 247 + 129 The program should allow the student to enter the answer. If the answer is correct, a message of congratulations should be displayed. If the answer is incorrect, a message showing the correct answer should be

Answers

Answer 1

Answer:

import random

num1 = random.randint(0, 1000)

num2 = random.randint(0, 1000)

print(str(num1) + " + " + str(num2) + " = ?")

result = int(input("Enter the answer: "))

if result == (num1 + num2):

   print("Congratulations!")

else:

   print("The correct answer is: " + str(num1 + num2))

Explanation:

*The code is in Python.

Import the random to be able to generate random numbers

Generate two numbers, num1 and num2, between 0 and 1000

Ask the sum of the num1 and num2

Get the input from the user

If the answer is correct, display a message of congratulations. Otherwise, display the correct answer


Related Questions

Select the correct answer. In which area is composing for games similar to composing for movies?
A. royalties earned
B. success of song-based soundtracks
C. usage of audio software for mixing and editing
D. spotting sessions

Answers

I believe the answer is c, hope this helps

Answer:

c

Explanation:

cuz im jus right

The head of small organization wants to install a network so that all the employees of different department can share various resources: I. What type of network he/she needs to set up in the organization? II. Name the resource that the employees will be able to share after setting up the network. ​

Answers

Answer:

While the Internet was evolving and creating a way for organizations to connect to each other and the world, another revolution was taking place inside organizations. The proliferation of personal computers inside organizations led to the need to share resources such as printers, scanners, and data. Organizations solved this problem through the creation of local area networks (LANs), which allowed computers to connect to each other and to peripherals. These same networks also allowed personal computers to hook up to legacy mainframe computers.

An LAN is (by definition) a local network, usually operating in the same building or on the same campus. When an organization needed to provide a network over a wider area (with locations in different cities or states, for example), they would build a wide area network (WAN).

CLIENT-SERVER

The personal computer originally was used as a stand-alone computing device. A program was installed on the computer and then used to do word processing or number crunching. However, with the advent of networking and local area networks, computers could work together to solve problems. Higher-end computers were installed as servers, and users on the local network could run applications and share information among departments and organizations. This is called client-server computing.

INTRANET

Just as organizations set up web sites to provide global access to information about their business, they also set up internal web pages to provide information about the organization to the employees. This internal set of web pages is called an intranet. Web pages on the intranet are not accessible to those outside the company; in fact, those pages would come up as “not found” if an employee tried to access them from outside the company’s network.

EXTRANET

Sometimes an organization wants to be able to collaborate with its customers or suppliers while at the same time maintaining the security of being inside its own network. In cases like this a company may want to create an extranet, which is a part of the company’s network that can be made available securely to those outside of the company. Extranets can be used to allow customers to log in and check the status of their orders, or for suppliers to check their customers’ inventory levels.

Sometimes, an organization will need to allow someone who is not located physically within its internal network to gain access. This access can be provided by a virtual private network (VPN). VPNs will be discussed further in the chapter 6 (on information security).

Here is the first line of a method declaration with some parts missing. public ________ scoreAnswer (studentAnswer ) Fill in the blanks in the method declaration using the following information: If scoreAnswer returns nothing and studentAnswer is a Paragraph object.

Answers

Answer:

void

Explanation:

The code snippet illustrates an object oriented programming (OOP)

From the question, the method name is scoreAnswer and it is not expected to return anything.

In OOP, when a method is expected to return nothing, the method is declared as void.

So, the blank will be replaced with the keyword void and the full statement is

public void scoreAnswer(studentAnswer)

A team of architects is designing a new AWS environment for a company which wants to migrate to the Cloud. The architects are considering the use of EC2 instances with instance store volumes. The architects realize that the data on the instance store volumes are ephemeral. Which action will not cause the data to be deleted on an instance store volume

Answers

Answer:reboot

Explanation:

Chris needs to create a simple web page with HTML. Which tool will he use? HyperText Web browser Text editor Operating software WILL GIVE 100 AND BRAINLIEST!!!!!!!!!!!!!!!!!!!!!!!!1

Answers

Answer:

The answer is "Text editor".

Explanation:

It is a computer program, which is used to provide editing on the plain text, and for this editing, we use a text editor. This tool differs from word processors software because it doesn't add additional text editing metals. In this tool, we also write the HTML code, and the incorrect choice can be defined as follows:

HyperText is a wrong choice because in these two or more pages are linked and it is used to move from one page to another. The Web browser is also a wrong choice because it is used to display the design of the web page. Operating software is also a wrong choice because it system software in which all things are done.  

Answer:

text editor

Explanation:

The ________ is the easy way to insert a new slide between existing slides.

Answers

What is the subject about?

i need a computer science help.....and I rlly want it right now...this the question
calculate all multiples of 5 that are less than a randomly generated number between 12 and 45. for example the random number is 16. the output is then 5,10,15 python

so basically if type a number between 12 and 45 it shud give me all the multiples of 5 less than the number i typed......pls help;-;

Answers

Define, en tus propias palabras, lo que son los sistemas de información.

how to print the output of "WELCOME" by using python codes with arrays.

Answers

Answer:

Following are the code to this question:

arr=['WELCOME']#defining list arr and assign string value

print (str(arr)[2:-2])#use print method that uses slicing to remove bracket and quotes

Output:

WELCOME

Explanation:

The Array data type is used to store the same type of value, but in python, the array is not used, instead of using an array we use the list, that stores multiple data types.

In the above code "arr", that is list is declared, that store a string value.    

To print its value, we use the print method, inside this, we use slicing to remove brackets and quotes.

General purpose computer can perform a single task, true or false​

Answers

Answer:

This is false.

Explanation:

General-purpose computers are desktop computers or laptops that can function in multiple ways. A special-purpose computer is usually designed to do one thing only.

i will mark brainalist! ​

Answers

Answer:

I would say

1) Weather Station

2) (word missing)

3) Robot perihen devices

4) Bit

5) Primary Key

6) Algorithim

7) Flow Chart

8) Table Wizard

9) Design View

10) SIMS

Answer:

i think it would be 1) Weather Station

2) (word missing)

3) Robot perihen devices

4) Bit

5) Primary Key

6) Algorithim

7) Flow Chart

8) Table Wizard

9) Design View

10) SIMS

Explanation:

Payroll deductions are the same for all employees. True False

Answers

Answer:

The answer is "False".

Explanation:

The Payroll deductions are the amount of each pay period, that is paid out of the paycheck of the employee. It is also considered as the money, which is deducted from its employees' paychecks so, if paid by the employers.

All staff members are not identical. Workers' paychecks determine the amount individuals receive during each pay cycle. It also is referred to it as payroll retainers.

You have a scenario where you need to disable the guest network on your wireless router. You try to log in, but your password does not work. After several attempts, you realize that you forgot your password. What can you do?

Answers

Answer:

Reset the router by holding down the reset button for 30 seconds. The reset button can be located in the back or bottom area of the router. The function of the reset button is to turn restore the wireless router to default factory setting such that customized settings including the DNS, the static IP address setup, stored personal passwords DHCP parameter settings port forwarding and routing settings are erased.

Explanation:

All of the following statements about MapReduce are true EXCEPT: MapReduce handles the complexities of network communication. MapReduce is a general-purpose execution engine. MapReduce handles parallel programming. MapReduce runs without fault tolerance.

Answers

Answer:

The correct option is;

MapReduce runs without fault tolerance

Explanation:

Map Reduce is a technique of processing or a framework of software, that is geared towards managing, sorting and handling large data by working in the Map and Reduce phases where the map function involves the dividing, filtering and sorting of the data and mapping of the split data while the reduce method involves the rearranging, summary activities having the data reduced.

Help me why did my desktop erase every app I need that please

Answers

Answer:

Your computer is affected by a polymorphic or trojan horse virus, so install avast antivirus. Set your computer into safe mode, then open the antivirus

Answer:

your pc has virus

Explanation:

difference between vacuum tube and transistor​

Answers

Answer:

I HOPE THE ABOVE INFORMATION WILL HELP YOU A LOT.

IblMessage.txt=welcome to fiji.what is the error in the coding and what type of error is it?(explain)​

Answers

Answer:

The correct syntax (assuming WinForms) is

lblMessage.Text = "Welcome to fiji";

The given statement fails to follow the syntax of literal strings, which should be in quotation marks. (depending on the framework and programming language, the txt property may also be incorrect, as well as the missing semi-colon).

1. Here is a program segment to find the quantity base . Both base and exp are entered at the keyboard. System.out.println("Enter base and exponent: "); double base = IO.readDouble();// read user input double exp = IO.readDouble(); // read user input /* code to find power, which equals baseexp */ System.out.print(base + " raised to the power " + exp); System.out.println(" equals " + power); Which code is a correct replacement for /* code to find power, which equals baseexp */ ?

Answers

Answer:

The correct code to this question can be de4fined as follows:

double power;

power = Math.pow(base, exp);

Explanation:

In the given question the choices were missing, that's why we defined the correct code only.

In the given code a two double variable "base and exp" is declared, that input the value from the user-side, and store its value into there respective variables. In the next step, "power", that is a double variable is declared, which uses the  "Math.pow" function that calculates given values power and prints its value.

please find the attachment of the full code.

Which of these would you use to connect a mouse to a computer?
O RAM
O ROM
O USB
O TOT

Answers

USB is the answer because that is the adapter to plug it in

in object oriented programming what is a constructor?

a. the attributes that allow a programmer to imagine a new object
b. the behaviors that allow a programmer to design a new object
c. the code that allows a programmer to create a new object
d. the template that allows a programmer to modify a new object

Answers

Answer:

The answer is A.

Answer:

A. the attributes that allow a programmer to imagine a new object

Explanation:

Got the answer right on the test!

I need help on my new iPhone 7 that I got I transfer my Sim card from my Samsung But before And after I put my Sim card in it was saying this please help...and yeah:( I’ll let give you fifty ..

Answers

Answer:

Sometimes phones do this, did you take it to the phone store?

Explanation:

In order to send and receive iMessages to your iPhone.

iMessage must be enabled. By doing this, you will associate your phone number with the email address used for your Apple ID or iCloud account.

What do computer programs generally try to solve and how? A) Computer programs generally try to solve a well-defined problem using a well-defined algorithm B) Computer programs try to solve poorly-defined problems using well-defined algorithms C) Computer programs try to solve well-defined problems using poorly-defined algorithms D) Computer programs try to solve math problems using only plain English

Answers

Explanation:

A) computer programs generally try to solve hard problems in a few seconds and makes us easy to learn

NIST recommends selecting cloud providers that support strong encryption, have appropriate redundancy mechanisms in place, employ authentication mechanisms, and offer subscribers sufficient visibility about mechanisms used to protect subscribers from other subscribers and the provider.a) trueb) false

Answers

Answer:

The answer is "Option a".

Explanation:

In cloud computing, it is also known as the model, that enables you for accessible, convenient, through the-demand network access to global computer resources, which can be rapid to get and published via low administrative effort.  

Its recommending selection for the cloud providers support for the robust encryption, that has adequate replication processes in place, use user authentication, or provide ample clarity to customers regarding mechanisms that defend subscriptions against other subscriptions and the supplier.

Technician A says that OBDI and OBDII use different DLC connectors. Technician B says that OBDII standardizes the designations for diagnostic trouble codes (DTCs). Who is correct? Technician A Technician B Both Technician A and Technician B Neither Technician A nor Technician B

Answers

Answer:

The answer is "Technician B"

Explanation:

The OBDII is a standardized, automated framework which the USA EPA had approved and installed into its whole year of modeling (MY) 1996 and then into modern light-duty vehicles and trucks, recognized as "on-board diagnostics II."  

The DTC framework is a set of problematic diagnostic codes that used alert you if a vehicle is unable to operate using an on-board Diagnostic System. If the system of the automobile identifies a problem, a special DTC code is generated as well as a position sensor is sent to the instrument cluster, that's why Technician B is correct.

A company runs an application on a fleet of EC2 instances. The company wants to automate the traditional maintenance job of running timely assessments and checking for OS vulnerabilities. As a Cloud Practitioner, which service will you suggest for this use case

Answers

Answer:

AWS Systems Manager

Explanation:

AWS Systems Manager (https://aws.amazon.com/systems-manager/features/) is the service that allows to centralize operational data from multiple AWS services and automate tasks across AWS resources.

solve plz
Jenae helps maintain her school web site and needs to create a web site poll for students. Which tool will she use?

JavaScript
HTML
CSS
Text editor

Answers

Answer:

HTML

Explanation:

HTML is used is making web pages.

Answer:

what

Explanation:

what do you mean by HDML coding ​

Answers

Answer:

hdml coding is a standard markup language for documents designed to be displayed in a web browser.

Explanation:

it can be assisted using things like CSS or JS

whats the recommended amount of dedodated wam
i can have in a server

Answers

Hi! The recommended amount of RAM that you should have is 6gb and above.

In 25 words or fewer, describe what Jaime could do at the guitar store to help customers satisfy their needs and wants.

Answers

Answer:

Jaime could allow the use of the guitars that are for sale within the store.

Explanation:

One of the biggest problems with these musical instrument stores is that you are not allowed to play the instruments unless you are going to buy them.

A store that allows the practice of these instruments within the establishment ensures that the customer tried to play the instrument, liked it, and decided to buy it.

It is a way to satisfy the customer.

Answer:

He could ask customers if they need help finding what they want. He can let his manager know if any product is running low.

Explanation:

legit the answer lol

What are the parts to an
email?

A)Recipient, Greeting, Body, Closing
B)Recipient, Subject, Body, Signature
C)Recipient, Subject, Greeting, Body, Closing, Signature
D)None of the above

Answers

Answer:

B) recipient subject body signature

List out analog computer​

Answers

Answer:

1. Wall clocks.

2. Analog watches

3. Measuring instruments with callibration

Explanation:

Other Questions
What kind of map would you use to see what people thought the world looked like 500 years ago? What would you do if fear was not a factor and you could not fail? 3. A doctor treated 2,000 patients over a period of time. If he worked for5 hours a day and spent 15 minutes pach patient, how many daysdid the doctor spend to treat all the patients? Solve for x. A. 19 B. 17 C. 15 D. 11 The Election of 1800 and the Twelfth Amendment In the election of 1800, the House of Representatives had to choose which candidates would run. select the winner. prevent political rivals from running together. 5+64this is TOTALLY SOOOO hard so help me^thats what she said Question 3 Multiple Choice Worth 2 points)04.04The swimming team has competed in 45 races this season. They have won 30 races so far. How many races will the team need to win today for the team to have a 75%Success rate?8101215 A dripping tap loses water at a rate of 5mL a minute. How long does it take to lose one litre? Type the correct answer in each boxThe general form of the equation of a circle is x^2+y^2+8x+22y+37=0The equation of this circle in standard form is (x+__)^2+(y+__)^2=__. The center of the circle is at the point (__,__). By what length will a slab of concrete that is originally 18 m long contract when the temperature drops from 24C to -16C? The coefficient of linear thermal expansion for this concrete is 1.0 10-5 C-1. 37can get a brochure on the second floor.(A). To participate (B). Participate (C). Participating (D). Participants 38. The..looked effective, and the board of directors liked it. (A). propose (B). proposal (C). proposed (D). proposes 39.An early..is required, especially in this kind of situation. (A). decide (B). decision (C). to decide (D). decided 40.The research shows that this .can cause big noise problems (A). some machineries (B). machineries (C). machinery (D). a machinery Two students use different methods to solve this multiplication problem:3/4*-4 2/9Read each of their methods below and then enter numbers to correctly complete theirwork. Total value systems work best ifMultiple Choice1. logistics is outsourced.2. all parts are strategically leveraged.3. individual elements focus on success.4. the process is outsourced.5. the process is completed in-house.In the international business world, the logistics function manages the global supply chain. The twin objectives of logistics are to manage a firm's global supply chain at the lowest possible cost and in a way that best serves customer needs.The potential for reducing costs through more efficient logistics can be achieved by using the just-in-time (JIT) inventory method as well as web-based information systems for modern materials management. Suggest any six ways to mobilize foreign donation properly. A baking scale measures mass to the tenth of a gram, up to 650 grams. Which of the following measurements is possible using this scale? a.3.8 grams b.120.01 grams c.800.0 grams d.54 milligrams Find an equation for the nth term of the arithmetic sequence. 9, 11, 13, 15, ... Drag the tiles to the correct boxes.to.complete the.pairs, Match the images with the stages of a mosquito's life cycle state three effects of malnutrition in farm animals 1 rabbit saw 9 elephants while going to the river. Every elephant saw 3 monkeys going to the river. Each monkey had 1 tortoise in each hand. How many animals were going to the river? give related words and complete the web - Picnic