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
andre [41]
3 years ago
6

Write a function mymin that has two str parameters and returns the smallest. (Smallest in the sense of coming first alphabetical

ly, not in the sense of "shortest".)

Social Studies
1 answer:
DerKrebs [107]3 years ago
6 0

Answer:

Complete Python code with explanation and output results is given below

Explanation:

A function named mymin is created which takes two arguments as input str_1 and str_2. Then using if else conditions compare them and return the smallest of them alphabetically.

To test the code, we called the function mymin three times with different inputs and each time the function mymin returned the correct values.

Python Code:

Function mymin:

def mymin(str_1,str_2):

   if str_1<str_2:

       return print("Smallest is:",str_1)

   else:

       return print("Smallest is:",str_2)

Test code:

mymin("Alpha","Beta")

mymin("Z","S")

mymin("Monday","Wednesday")

Output:

Smallest is: Alpha  

Smallest is: S  

Smallest is: Monday

(Alphabetically Alpha comes first than Beta)

(Alphabetically S comes first than Z)

(Alphabetically Monday comes first than Wednesday)

You might be interested in
What is a closed primary?
drek231 [11]

A party election where only registered democrats or republicans can vote

6 0
3 years ago
Tameka is reading a novel. When the phone rings, she looks up to see if her husband is going to answer it, which he does. She re
grin007 [14]

Answershes probably distracted.

Explanation:

4 0
3 years ago
Informed consent means that:_______.
djyliett [7]

Answer:

b) subjects agree to participate in a study after receiving complete information about the nature and purpose of the study.

Explanation:

In research, the term informed consent refers to the process in which researchers get a voluntary agreement from participants of the study where they state they are willing to participate on it.

This consent involves informing the subjects about their rights, the procedures they will undergone to, the purpose of the study and the risks and benefits they might have. However, in this consent the researchers <u>do not disclose the hypothesis of the study because this might put in risk the results of the study </u>(since participants might change their behavior due to this).

Therefore, the correct answer is that informed consent means that b) subjects agree to participate in a study after receiving complete information about the nature and purpose of the study.

7 0
3 years ago
What were some responsibilities adult male citizens had?
devlian [24]

1) Support and defend the Constitution

2) Stay informed of the issues affecting your community

3 Participate in the democratic process

4) Respect and obey federal, state, and local laws

5) Respect the rights, beliefs, and opinions of others

6) Participate in your local community

8 0
2 years ago
What direction is toward the south pole?
Vlad1618 [11]

Answer: South

Explanation:

5 0
3 years ago
Other questions:
  • Which of the following do NOT describe a typical flapper? long hair light makeup strings of beads short hair style long, waistle
    7·2 answers
  • Tariffs and import quotas can reduce unemployment in a U.S. import industry, but a. foreign countries could impose nontariff bar
    12·1 answer
  • Why was augustus so concerned with the moral state of the roman elite?
    8·1 answer
  • Many countries have adopted programs to supplement children older than 6 months and pregnant women with
    5·1 answer
  • When Josh was dropped off at preschool on the very first day of class, he was quite upset. He cried for a long time and would no
    7·1 answer
  • An easement that is not created by express statements between the parties; but as a result of surrounding circumstances that dic
    10·1 answer
  • Explain what the city manager does in a city government.
    11·1 answer
  • In your own words, describe why voting by mail can cost less than in-person voting.
    8·1 answer
  • Sort the characteristics that descnbe each culture. Aryan Dravidian lived in large cities headed by men had a strong central gov
    13·1 answer
  • Why does the canadian government have to work with the U.S. government to clean up the great lakes
    11·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!