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
3. Which of the following is not a responsibility of the government?
Oksana_A [137]

To sort out conflict

Because its not the governments job to fix peoples problems with other citizens.

3 0
3 years ago
Read 2 more answers
True or false in a communist country everyone is given more than what they need to survive
Furkat [3]

Answer:

it is false

Explanation:

7 0
2 years ago
Read 2 more answers
Prosperity and depression portfolio!’ has anybody done this? i need help!
Black_prince [1.1K]
Yeah I have it’s that you have to connect the pines and then submit it
6 0
3 years ago
Synthesia is a phenomenon which has been estimated to occur in only a few people in a million. Due to its rarity, researchers ar
Alina [70]

Answer:

Case Study

Explanation:

According to my research on the different types of research methodologies, I can say that based on the information provided within the question due to its rarity the most likely research method to be used would be a Case Study. This is a method of making an up-close, in-depth, and detailed examination of the object/subject being studied.

I hope this answered your question. If you have any more questions feel free to ask away at Brainly.

5 0
3 years ago
The boston tea party was largely a response to the:
Black_prince [1.1K]
The coercive act aka the intolerable act
6 0
2 years ago
Read 2 more answers
Other questions:
  • The _____ have the power to decide whether or not an action of the government violates the Constitution.
    8·2 answers
  • Explain how the tone and style of persuasive messages impact their persuasiveness. Specifically, address how personal touch, act
    12·1 answer
  • Jewish &amp; christian teaching helped contribute to the spread &amp; development of.?
    12·1 answer
  • How many countries were economically impacted by the creation of a T-shirt? The other question is Explain how technology has mad
    5·2 answers
  • What is a peace treaty?
    12·2 answers
  • What are detention and correctional facilities? how are they different?
    11·2 answers
  • There is absolutely no place in this land for the arrogant,
    11·2 answers
  • What was John Adams greatest asset?
    6·1 answer
  • Cell : nucleus :: __ : engine
    10·1 answer
  • NEED THIS QUESTION ANSWERED QUICKLY AND SERIOUSLY
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!