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
erik [133]
3 years ago
9

Write a Python program that gets a single character from the user and writes out a congratulatory message if the character is a

vowel (a, e, i, o, or u), but otherwise writes out a "You lose, better luck next time" message.
Computers and Technology
1 answer:
DochEvi [55]3 years ago
8 0

Answer:

def vowel(a):  #function to detect whether the character is vowel or not.

   vow=['a','e','i','o','u'] #list of vowels.

   if a in vow:

       return True

   else:

       return False

       

character=str(input("Enter the character \n")) #taking input.

if vowel(character.lower()):#checking the character is vowel using the function vowel..

   print("Congratulations!!!!") #congratulating.

else:

   print("You lose better luck next time")#message.

Output:-

Enter the character  

a

Congratulations!!!!

Explanation:

I have created a function to check whether the given character is a vowel or not.

After that taking input from the user.

And checking that it is vowel or not.If it is vowel then printing the message.

You might be interested in
If you posted an advertisement for your research study on marriage on the Internet and the couples who responded (i.e., the coup
WITCHER [35]

Answer:

B. volunteer bias.

Explanation:

-Experimenter bias is when the expectations of the experimenter in regards to the outcome are communicated to the participants in any form.

-Volunteer bias refers to a situation in which the people that volunteer to take place in a study doesn't represent the general public.

-Research bias is when the experimenter influence the result to get a specific outcome.

-Social desirability bias is when the people taking part in a study give their responses in a way that is viewed as favorable.

According to this, the answer is that the situation would be an example of volunteer bias.

3 0
3 years ago
Hooollaaaa , todos absolutamente todos quieren borrar esta tarea por que no tiene nada que ver con la materias del colegiooo per
Andreas93 [3]

Answer:

JAJAJSJJS XD PERO SI SOY

7 0
2 years ago
Read 2 more answers
Can you get shocked from a breaker box?
Mashcka [7]
I dont think it would, but maybe you should Google it just in case.
4 0
3 years ago
Change the function definition for myint so that xyzfunc uses the same memory locations for myint as in the calling program.
sattari [20]

Answer:

b) void xyzfunc (int &myint);

Explanation:

To use the same memory location as the variable in the calling function we have to pass the variable by reference means passing the same address to the function.So to do that we have use & operator which stands for address.

We will do this as following:-

void xyzfunc (int * myint);

Hence the answer is option b.

8 0
3 years ago
A Supermarket manager hired one packager who can pack 15 boxes every two minutes. Ater some time the manager noticed that packag
Semenov [28]

Answer:

40mn

Explanation:

500/t=15/2+15/3

500/t=75/6

75t=500×6

t=3000/75

t=40

6 0
2 years ago
Read 2 more answers
Other questions:
  • Most users find settings between ____ to be the most convenient option for how long the computer sits idle before the screen sav
    14·1 answer
  • Error messages begin with the ____ symbol.
    6·2 answers
  • An IT specialist is consulted about setting up a peer-to-peer network. What would the specialist say about security risk in this
    14·2 answers
  • . Select the advantages of RAID-5 relative to other RAID schemes. (MAY SELECT MULTIPLE)
    7·1 answer
  • Which of the following is a sample IPv4 address?
    14·1 answer
  • I NEED A BIG BRAIN BOYO TO HELP ME
    14·1 answer
  • Hello guys please help me <br>list and identify the components of computer ​
    15·1 answer
  • When Alice turned on her laptop this morning, the screen displayed only colorful horizontal lines. Which of the following is mos
    15·1 answer
  • A __________is a software program that appears to be a physical computer and executes programs as if it were a physical computer
    14·1 answer
  • Which web-authoring software enables users to create sophisticated web pages without knowing any html code?.
    15·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!