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
Alinara [238K]
3 years ago
15

Write a program that asks the user to enter two integer numbers X and Y. The program halves each number between X and Y then pri

nts the values on the screen. For example: If X=5 and Y=7, the program prints the following values 5/2=2.5, 6/2=3.0 and 7/2=3.5 Sample run 1: Enter X and Y: 5 7 2.5 3 3.5 Sample run 2: Enter X and Y: 15 10 5.0 5.5 6.0 6.5 7.0 7.5

Computers and Technology
1 answer:
QveST [7]3 years ago
5 0

Answer:

`I wrote a quick script in Python, to get you started a little basic and doesn't cover much but it works

Explanation:

starting off x = input(...) and y = input(...) is simply grabbing the input from the users then I make a base array vals defined like:

vals = []

to store the calculated results

rx = int(x) and ry = int(y), are simply converting the x, y which are strings into a int type, so I can use them on this line:

for i in range(rx, (ry + 1)):

I added the + 1 to ry because the range ends at the number before Y, example:

for i in range(5, 8):

 print(i) -> 5,6,7

with all of that I simply ran an iteration <em>for loop</em> and calculated and store the results into vals presented here:

vals.append(i / 2)

If there's any confusion leave a comment I'll try my best to help out

You might be interested in
Ummm, I hate to interrupt your day, but does anyone know where Mitch72 is????? Because he hasn't talked in a week, and he hasn't
Anettt [7]

Answer:

sorry but no

Explanation:

4 0
3 years ago
When a user runs a program in a text-based environment, such as the command line, what determines the order in which things happ
Svetradugi [14.3K]

Explanation:

In general, when a program runs in text-based environment like command line interface, the program is used for determining the order in which things happen.

As the program runs, the user will not have any choice and he or she can enter the required data.

If the user enters the data in required format then, he/she can get the result or output in desired format.

7 0
4 years ago
How do you print a document?
Monica [59]
Control + P (push these buttons at the same time)

or right click and print.

if you are printing a webpage, the steps are the same.

if you are using Word, then you just need to find the File tab and print should be in the list.
3 0
3 years ago
Pls help? \/<br><br>https://youtu.be/kDmXlM50API<br>Click there and go to my channel and $ub
WITCHER [35]

Coming from a person with a Y-ouTube channel with more than 50 s-ubscribers, here are some tips if you want to be serious about starting this.

1. Don't ask for s-ubs. It never works, and it won't ever. That's not a good way to promote your channel. Especially on a school website. You have to work hard for your s-ubscribers, because if you ask for them, you won't have real fans. They'll only be there as a number, not viewing your videos, just staying there. I don't ask my viewers to s-ubscribe, because that's their choice and I don't want to force them to do anything. If you don't ask for s-ubs, people will view you as a person who cares for people's opinions and doesn't tell people what they should do. Also, you have to have 1,000 subs, 4 live watch hours, and more than 10k views to get paid.

2. Don't post random videos. Set up your channel first. If you post random things, your channel won't grow at all because people only s-ubscribe if they really like the person's original content or the person themselves.

3. Remember, quality not quantity. Just because you post multiple videos, doesn't mean you'll get many views. Quality in this case means to put real effort into your videos. Taking the time to make thumbnails, full descriptions, etc. Quantity means that you only care about how many videos come out.

4. DON'T COPY OTHERS. Make your own content (also don't clickbait). If you make your own content people will s-ubscribe for your originality, and they'll be more interested in your content.

5. Look at your comments and interact with your s-ubscribers. Y-ouTube loves that. Don't ignore them, and make them know that they're special.

6. Take criticism. I'm guessing since you became a Y-ouTuber, you already know that you're bound to get hate. If someone comments something rude, delete it, block the person and move on. Don't start a meaningless argument. If someone gives constructive criticism, just respond with something like "Okay, thanks for the feedback!".

I hope this helped you learn more things about becoming a Y-ouTuber :)

3 0
3 years ago
The area where a blast originates is referred to what perimeter/isolation zone
Anna [14]
The area where a blast originate from is referred to as PERIMETER. After a bomb blast incident, the first responders has to map out a safe pre-blast perimeter based on the requirements of Bureau of Alcohol, Tobacco, Firearms and Explosives [BATFE]. After this, the first inner perimeter, also called hot zone must be established. This is where the blast originated from and it is the point where victims rescue and treatment will start.
8 0
3 years ago
Other questions:
  • In this program you will read in the number of seconds and convert it to days, hours, minutes and remaining seconds. Your progra
    10·1 answer
  • How to screen shot on a computer
    14·2 answers
  • Explain why living things store energy in lipids instead of in carbohydrates
    5·1 answer
  • Două numere a și b sunt numite generatoare ale unui număr natural n dacă a∙b+[a/b]=n, unde s-a notat cu [c] partea întreagă a nu
    7·1 answer
  • HELP FAST PLEASE!!! What is a glass tube containing electrodes used as a switch to produce on or off signals for the computer? F
    10·1 answer
  • Given an 10-bit two's complement binary number, what is the decimal value of the largest negative integer that can be represente
    10·1 answer
  • 45 points!!
    15·2 answers
  • If you are going to build a custom fast PC for gaming and you need a lot of storage for big video files and videos, but you have
    11·1 answer
  • Why isn't image display working on wacom tablet.
    8·1 answer
  • In cell K10, create a formula using the SUM function that calculated the total of the range F17:F20 subtracts it from the value
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!