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
GarryVolchara [31]
3 years ago
15

Create a program in Python that prompts the user to enter an integer number within the range of 1 to 10 inclusive. The program s

hould display “correct input” if the input is within the given range else it should display “wrong input”.

Computers and Technology
2 answers:
lapo4ka [179]3 years ago
8 0

Answer:

dont know if it works!

Explanation:

input=(input("enter number")

if input > 1

print("correct input")

if input <10

print("correct input")

else

print("wrong input")

Gwar [14]3 years ago
7 0

Python Code with Explanation:

# create a function named func to implement the required logic

def func():

# get the input from the user and store it in a variable named number

   number = int(input("Please enter an integer between 1 to 10 inclusive\n"))

# if the input number is equal or greater than 1 and equal to 10 or less then the input is correct    

   if number>=1 and number<=10:

# print correct input

       return print("Correct input")

# else the input is wrong

   else:

# print wrong input

       return print("Wrong input")

# call the function func

func()

Output:

Test 1:

Please enter an integer between 1 to 10 inclusive

4

Correct input

Test 2:

Please enter an integer between 1 to 10 inclusive

0

Wrong input

Test 3:

Please enter an integer between 1 to 10 inclusive

11

Wrong input

You might be interested in
Which amendment applies to the following scenario? “Brian attended church with his two daughters and wife on Sunday." A First B
iragen [17]

Answer: First Amendment

Explanation:

The First Amendment gives individuals the freedom of speech and the right to proactive any religion that they want. It also allows the people have a peaceful protest.

The swcud amendment gives people the right to keep arms. The Fourth hinders individuals from being searched without a warrant.

Therefore, the answer is First Amendment.

4 0
3 years ago
Small programs called _______ are used to communicate with Paris Friel devices such as monitors printers portable storage device
algol13

the answer is D drivers

7 0
3 years ago
A computer connected to the Internet that asks for data is a(n) ________. Select one: A. server B. client C. aggregator D. surro
madreJ [45]

Answer:

client

Explanation:

The client makes a request for a service, and a server performs that service.

7 0
3 years ago
What are the three parts of a camera
son4ous [18]

Answer: Camera lens, Film or sensors, and body.

Explanation: I researched it.

8 0
2 years ago
In Scratch, you have to choose backdrops from a limited number in the Scratch image library.
forsale [732]
I would say it would be True
5 0
3 years ago
Other questions:
  • What executable programs have names that are just one character long, and what do they do??
    5·1 answer
  • GAMES Which is better Roblox or BattleCamp Basically Free Points But Please Answer
    7·2 answers
  • Please check my answer! (Java)
    7·1 answer
  • What are the benefits of team collaboration?
    13·2 answers
  • A company accidentally sends a newsletter with a mistyped website address. The address points to a website that has been spoofed
    8·1 answer
  • Which documents might an employer expect to find in a career portfolio?
    15·2 answers
  • What is the meaning of the term plot?<br>A. the final outcome of the story​
    8·1 answer
  • Write the use of these computers.
    14·1 answer
  • Most case fans have standard _______________ connectors that are easy to plug in but can be forced to be connected the wrong way
    14·1 answer
  • Why is a salt added to a password that is being stored in a database?
    5·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!