chubbybunny1304 chubbybunny1304
  • 21-07-2022
  • Computers and Technology
contestada

Create a conditional expression that evaluates to string negative if user_val is less than 0, and non-negative otherwise.

Respuesta :

1207449
1207449 1207449
  • 21-07-2022

Answer: I am supposed to write a few lines of code to create a conditional expression (ternary operation) that evaluates to string "negative" if user_val is less than 0 and "non-negative" if 0 or greater than 0.

The code I currently have prints "negative" when the number is less than zero but when a number 0 or greater is assigned to user_val it doesn't print "non-negative."

Answer Link

Otras preguntas

Rocky point brewery (rpb) plans to file an initial public offering (ipo) in june 20x3. Olsen & alain, cpas (o&a) has performed calendar year end audits
Please help. and i forget which subject that life skills will be in so sorry for wrong subject Discussion 5.2: Advertising Techniques Advertisers can be very cl
Which choices are equivalent to the expression below? Check all that apply. 5/3 I A. 75 ] B. v3.15 I C. 75 O D. 125. 3 IE. 45 0 F 15.15
Help help help math math
Which of the following are possible results of environmental tobacco smoke? A-Lung cancer B-reduced heart function C-asthma and ear infections in children D-a
oración a san judas tadeo para conseguir dinero urgente
QUESTION 23.PLEASE HELP ASAP
Why the body needs more water after exercising/performing rigorous activity
Which word is a synonym of bestow? HELPPPP MEEEE PLZZZZ!!!!!!!!!!!!!
The dewpoint is 15°c. What is the wet-bulb temperature on a sling psychrometer if the dry-bulb temperature is 18°c?.