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
Leona [35]
4 years ago
8

The longest_word function is used to compare 3 words. It should return the word with the most number of characters (and the firs

t in the list when they have the same length). Fill in the blank to make this happen.
Engineering
1 answer:
NARA [144]4 years ago
4 0

Answer:

len(word2) >= len(word1) and len(word2) >= len(word3):

Question with blank is below

def longest_word(word1,word2,word3):

   if len(word1) >= len(word2) and len(word1) >= len(word3):

       word = word1

   elif _________________________________________

       word = word2

   else:

       word = word3

   return word

print(longest_word("chair","couch","table"))

print(longest_word("bed","bath","beyond"))

print(longest_word("laptop","notebook","desktop"))

print(longest_word("hi","cat","Cow"))

Explanation

In line 1 of the code word1, word2, and word3 are the parameters used to for the defining the longest_word function. They will be replaced by 3 words to be compared. The code that is filled in the blank is len(word2) >= len(word1) and len(word2) >= len(word3): It is a conditional statement that is true only if the number of characters in the string of word2 is greater than or equal to word1 and word2 is greater than that of word3 .

You might be interested in
Select the best answer to the questo
Norma-Jean [14]

Answer:

C

Explanation:

7 0
3 years ago
Read 2 more answers
1. In a base bias configuration with a supply voltage is 15v, what does Ver equal when reverse biased?
wlad13 [49]
The answer is C!!!!!!!!
3 0
3 years ago
At steady state, a reversible refrigeration cycle discharges energy at the rate QH to a hot reservoir at temperature TH, while r
ludmilkaskok [199]

Answer:

a) COP_{R} = 25.014, b) T_{H} = 327.78\,K\,(54.63\,^{\textdegree}C)

Explanation:

a) The coefficient of performance of a reversible refrigeration cycle is:

COP_{R} = \frac{T_{L}}{T_{H}-T_{L}}

Temperatures must be written on absolute scales (Kelvin for SI units, Rankine for Imperial units)

COP_{R} = \frac{275.15\,K}{286.15\,K-275.15\,K}

COP_{R} = 25.014

b) The respective coefficient of performance is determined:

COP_{R} = \frac{Q_{L}}{Q_{H}-Q_{L}}

COP_{R} = \frac{8.75\,kW}{10.5\,kW-8.75\,kW}

COP_{R} = 5

But:

COP_{R} = \frac{T_{L}}{T_{H}-T_{L}}

The temperature at hot reservoir is found with some algebraic help:

COP_{R} \cdot (T_{H}-T_{L})=T_{L}

T_{H}-T_{L} = \frac{T_{L}}{COP_{R}}

T_{H} = T_{L}\cdot \left(1+\frac{1}{COP_{R}}  \right)

T_{H} = 273.15\,K \cdot \left(1+\frac{1}{5}  \right)

T_{H} = 327.78\,K\,(54.63\,^{\textdegree}C)

8 0
3 years ago
Read 2 more answers
A resistance of 30Ω is placed in a circuit with a 90 volt battery. What current flows in the circuit?
Svetlanka [38]

Answer:

30 Amperes

Explanation:

if    V ⇒ voltage

      I ⇒ current

      R ⇒ resistance

V = IR

90 = I x 30

90/30 = I

3 = I

6 0
2 years ago
An electric dipole is made of two charges of equal magnitudes and opposite signs. The positive charge, q=1.0 μC, is located at t
vfiekz [6]

Answer:

work done by electric field  is 0.06 J

Explanation:

Given data:

Two point charge is + 1\mu C  and -1 \mu C

0+1 charge positioned is (0 cm , 1 cm, 0.00 cm)

-1 charge positioned is (0 cm , -1 cm, 0.00 cm)

E = 3.0\times 10^6 N/C

From above information, the distance between  given two charges d = 2 cm

then d = 0.02m

 work needed is W = q E d

W = 1.0 \times 10^{-6} \times 3.0 \times 10^6 \times 0.02

W = 0.06 J  

Therefore work done by electric field  is 0.06 J

8 0
3 years ago
Other questions:
  • A steam pipe passes through a chemical plant, where wind passes in cross-flow over the outside of the pipe. The steam is saturat
    13·1 answer
  • A surveyor is trying to find the height of a hill . he/she takes a sight on the top of the hill and find that the angle of eleva
    12·1 answer
  • In Visual Basic/Visual Studio, characteristics of controls, such as the Name of the control, or the Text displayed on the contro
    10·1 answer
  • Consider a process in which a carbon-based fuel is combusted in the presence of 70% excess oxygen (assume that all of the oxygen
    10·1 answer
  • Lately, you have noticed some repetitive stress in your wrist. Which sign is most likely the cause of that stress and pain?
    7·1 answer
  • Prove the following languages are nonregular, once using the pumping lemma and once using the Myhill-Nerode theorem. When using
    15·1 answer
  • What is the key to being a good engineer?
    15·2 answers
  • Air, at a free-stream temperature of 27.0°C and a pressure of 1.00 atm, flows over the top surface of a flat plate in parallel f
    13·1 answer
  • Please help been stuck on this for a couple minutes
    5·1 answer
  • Which option identifies the concept represented in the following scenario?
    7·1 answer
Add answer
Login
Not registered? Fast signup
Signup
Login Signup
Ask question!