menu
QAmmunity.org
Login
Register
My account
Edit my Profile
Private messages
My favorites
Register
Ask a Question
Questions
Unanswered
Tags
Categories
Ask a Question
Assume choice refers to a string. The following if statement determines whether choice is equal to Y or y. if choice == 'Y' or choice == 'y': Rewrite this statement so it only makes one comparison and
asked
Oct 17, 2024
66.7k
views
0
votes
Assume choice refers to a string. The following if statement determines whether choice is equal to Y or y.
if choice == 'Y' or choice == 'y':
Rewrite this statement so it only makes one comparison and does not use the or operator. Write this in Python
Computers and Technology
high-school
Sungryeol
asked
by
Sungryeol
8.4k
points
answer
comment
share this
share
0 Comments
Please
log in
or
register
to add a comment.
Please
log in
or
register
to answer this question.
1
Answer
4
votes
Answer:
if choice.lower() == 'y':
Step-by-step explanation:
PunctuallyChallenged
answered
Oct 22, 2024
by
PunctuallyChallenged
8.4k
points
ask related question
comment
share this
0 Comments
Please
log in
or
register
to add a comment.
Ask a Question
Welcome to QAmmunity.org, where you can ask questions and receive answers from other members of our community.
9.4m
questions
12.1m
answers
Other Questions
“What does it mean when we “rework” copyrighted material?”
The book shows how to add and subtract binary and decimal numbers. However, other numbering systems are also very popular when dealing with computers. The octal (base 8) numbering system is one of these.
Seven basic internal components found in a computer tower
describe an advance in technology that makes life more enjoyable. what discoveries contribute to this technology?
Disadvantages of using animation in advertising? advantages and disadvantages of using animation for education? advantages and disadvantages of using animation in entertainment?
Twitter
WhatsApp
Facebook
Reddit
LinkedIn
Email
Link Copied!
Copy
Search QAmmunity.org