KnowledgeBoat Logo

Computer Science

Make change in the expression for z in the Python code given below so that the output produced is zero. You cannot change the operators and order of variables. (Hint. Use a function around a sub-expression)

x, y = 4, 8
z = x/y*y 
print(z)

Python Data Handling

21 Likes

Answer

x, y = 4, 8
z = int(x/y)*y 
print(z)

Answered By

12 Likes


Related Questions