Quiz: Python Numbers


Complete the following exercises and submit your code:

# Convert one type to another:

x = 8    # int
y = 1.3  # float

# 1. Convert from int to float:

# 2. Convert from float to int:

# 3. Write a Python program to convert an integer to binary. 
# Tip: search for the function 'format'

x = 11


  • Is there anything we can help with up to this point? Do you have something to suggest about this chapter? Let us know in the comments below.

Leave a Reply