Create a conditional expression that evaluates to string "negative" if user_val is less than 0, and "non-negative" otherwise. Sample output with input: -9-9 is negative Use Python for this, please.

Microsoft Visual C#
7th Edition
ISBN:9781337102100
Author:Joyce, Farrell.
Publisher:Joyce, Farrell.
Chapter14: Files And Streams
Section: Chapter Questions
Problem 2CP: In Chapter 11, you created the most recent version of the MarshallsRevenue program, which prompts...
icon
Related questions
Question

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

Sample output with input: -9-9 is negative

Use Python for this, please.

344614.2153518.qx3zqy7
1 user_val = int(input())
1 test
2
passed
3 cond str -' Your solution goes here "
4
5 print(user_val, 'is', cond_str)
All tests
passed
Run
View your last submission
Transcribed Image Text:344614.2153518.qx3zqy7 1 user_val = int(input()) 1 test 2 passed 3 cond str -' Your solution goes here " 4 5 print(user_val, 'is', cond_str) All tests passed Run View your last submission
Expert Solution
trending now

Trending now

This is a popular solution!

steps

Step by step

Solved in 2 steps with 3 images

Blurred answer
Similar questions
  • SEE MORE QUESTIONS
Recommended textbooks for you
Microsoft Visual C#
Microsoft Visual C#
Computer Science
ISBN:
9781337102100
Author:
Joyce, Farrell.
Publisher:
Cengage Learning,
EBK JAVA PROGRAMMING
EBK JAVA PROGRAMMING
Computer Science
ISBN:
9781337671385
Author:
FARRELL
Publisher:
CENGAGE LEARNING - CONSIGNMENT