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
castortr0y [4]
3 years ago
8

Flowgorithm, Design a program that prompts the user to enter a number within the range of 1 through 10. The program should displ

ay the Roman numeral version of that number. If the number is outside the range of 1 through 10, the program should display an error message?

Computers and Technology
1 answer:
kherson [118]3 years ago
6 0

Answer:

Step by step code along with explanation and output is given below

Explanation:

We can solve this problem using if elif else approach

def main():

# prompts the user to enter an integer from 1 to 10

 num = int (input('Enter a number in the range of 1 to 10:\n'))

# using the if elif print out the roman numeral from 1 to 10

 if num == 1:

   print ('Roman Numeral for 1 is I')

 elif num == 2:

   print ('Roman Numeral for 2 is II')

 elif num == 3:

   print ('Roman Numeral for 3 is III')

 elif num == 4:

   print ('Roman Numeral for 4 is IV')

 elif num == 5:

   print ('Roman Numeral for 5 is V')

 elif num == 6:

   print ('Roman Numeral for 6 is VI')

 elif num == 7:

   print ('Roman Numeral for 7 is VII')

 elif num == 8:

   print ('Roman Numeral for 8 is VIII')

 elif num == 9:

   print ('Roman Numeral for 9 is IX')

 elif num == 10:

   print ('Roman Numeral for 10 is X')

# using the else print out error message whenever user enters any other number not listed above

 else:

   print ('Error! Wrong Input')

# call the main function

main()

Output:

Enter a number in the range of 1 to 10:

6

Roman Numeral for 6 is VI

Enter a number in the range of 1 to 10:

15

Error! Wrong Input

You might be interested in
Default tab stops are set in word every ___________ inch.
iren [92.7K]
They are set every 1 inch.
6 0
3 years ago
If there was no technological advancement what would be our society like​
blondinia [14]

Answer:

WHAT SOCIETY?!

Every night we'd still be squatting in caves, hunched around campfires, waiting for the leopards to pick us off....

It's hard to have a society when your means of communication are nearly zero and therefore can't sustain the dialogue necessary to develop the shared values needed to form a society.

8 0
2 years ago
A technician would like to have the ability to add physical hard drives to a Storage Spaces storage pool at future times on an a
Iteru [2.4K]

Answer:

b. Thin provisioning

Explanation:

Thin provisioning is a storage space feature that makes allocating disk storage space flexible based on the space needed by each user, it improves the way storage space is utilized.

5 0
3 years ago
Hoda needs to create a chart that is associated with an Excel spreadsheet. She needs to ensure that if the data in the spreadshe
omeli [17]

Answer:

Link the chart.

Explanation:

Microsoft Excel is a software application or program designed and developed by Microsoft Inc., for analyzing and visualizing spreadsheet documents.

A spreadsheet can be defined as a file or document which comprises of cells in a tabulated format (rows and columns) typically used for formatting, arranging, analyzing, storing, calculating and sorting data on computer systems.

In this scenario, Hoda needs to create a chart that is associated with an Excel spreadsheet. Also, she wants the data in the spreadsheet to change as soon as the chart in her presentation is updated. Thus, the option she must choose is to link the chart with the spreadsheet.

In the source spreadsheet, she should select a chart and the cell where she wants the hyperlink to appear. Then, she should create a hyperlink that links to the spreadsheet.

8 0
3 years ago
a. Write a function called fizzbuzz. This function will take 1 number as a parameter. The function will print all numbers from 0
OLga [1]

Answer:

def fizzbuzz (num):

 for item in range(num):

   if item % 2 == 0 and item % 3 == 0:

     print("fizzbuzz")

   elif item % 3 == 0:

     print("buzz")

   elif item % 2 == 0:

     print("fizz")  

   else:

     print (item)

fizzbuzz(20)

Explanation:

Using Python programming Language

Use a for  loop to iterate from 0 up to the number using the range function

Within the for loop use the modulo (%) operator to determine divisibility by 2 and 3 and print the required output

see attached program output screen.

5 0
3 years ago
Other questions:
  • Isaac is researching Abraham Lincoln’s life for a social studies report. He finds an encyclopedia that includes original letters
    5·2 answers
  • True or false over the course of ecological succession,species diversity increases over time?
    12·2 answers
  • Write an expression that evaluates to true if and only if the value of the integer variable workedOvertime is true.
    7·1 answer
  • Give one advantage and two disadvantages of using a wireless network
    8·1 answer
  • To create a new folder, press ____.
    12·1 answer
  • g What field in the IPv4 datagram header can be used to ensure that a packet is forwarded through no more than N routers? When a
    10·1 answer
  • To rotate text in a cell select the option in the alignment grouping
    9·2 answers
  • How do programmers recognise patterns, generalise and abstract information
    13·1 answer
  • Write the use of these computers.
    14·1 answer
  • Five types of conflict in the school​
    9·2 answers
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!