Question: USING PYTHON ou are given a positive integer (whole number) stored in a variable called X. Use a chained conditional to implement these rules in
USING PYTHON ou are given a positive integer (whole number) stored in a variable called X. Use a chained conditional to implement these rules in Python (hint: for evenly divisible, try using the modulus operator described in section 5.1 of ThinkPython 2E): If this number is evenly divisible by 3 but not 5, print "only 3" If this number is evenly divisible by 5, but not 3, print "only 5" If this number is evenly divisible by both 3 and 5, print "3 and 5" Otherwise (not evenly divisible by either), print "none"
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
