+ 1
Whats my mistake in this code? I need help
items = int(input()) days = int(input()) while days>0: items= (6*2) days-=2 print(items)
5 Answers
+ 2
Hi! to earn a loop, make at least three indents (spaces) to the right in the lines that follow "while" below.
p.s.
items = int(input())
days = int(input())
while days>0:
items= (6*2)
days-=2
print(items)
+ 2
Really.....
+ 1
Bright Nzidee What is the output you were expecting?
0
Bright Nzidee If you move the print to the same level as the rest, the while loop will pick it up.
Not sure of your intended behavior but setting items = 12 no matter what, seems a little odd items=(6*2)
https://code.sololearn.com/ce399sDyft41/?ref=app