0

Do you have practice problems for conditions?

Please give me some practice problems to master conditions in python. Thank you.

26th Jun 2022, 2:00 AM
Dienel Manipol
Dienel Manipol - avatar
2 Antworten
0
#Even or Odd Number - Input a number. Print "Odd" if number is odd and print "Even if number is even #Young or Old - Input a number(age). Prints "young" if age is below for example 20. Prints "old" if age is more than 20. #Coin flip - Input 0 or 1. Code will generate random number(either 0 or 1). If the generated number is 0 print "head". If the generated is 1 print "tail". Also print if you win or lose if your input matches the generated number
26th Jun 2022, 4:32 AM
Jonathan T Rantael
Jonathan T Rantael - avatar
0
Easy #absolute value Medium #number of vowels in a string Harder #does string have substring x
26th Jun 2022, 7:30 PM
madeline
madeline - avatar