✅ The verified answer to this question is available below. Our community-reviewed solutions help you understand the material better.
Here is a program that converts a decimal number to binary. Identify which line contains an error:
n = int(input())
ds = []
while n // 2 != 0:
ds.append(n % 2)
n = n / 2
ds.append(n % 2)
for i in range(len(ds) - 1, -1, -1):
print(ds[i], end='')