Exercise Bug



I couldn't find where to report a potential bug, but i'm sure this code wasn't supposed to be correct:


Hi @universol,
Your program works as intended?
Can you explain what you find is odd or probable bug?


The SCT can see required elements, but is not checking the order or the output. So long as you went back and did the exercise as expected and could still pass it is not considered to be a bug.


There is only one input, and it is not inside the loop where it is supposed to be. golfing is being appended three times to the list, instead of three different hobbies. As stated, not a bug, just the SCT seeing the required elements so passing it. As for the printing that was not asked for, the SCT must be ignoring that.


"Create a for loop that prompts the user for a hobby 3 times."

My code prompted once, appended the hobby as intended, and then printed 0, 1, 2 with no further prompts.


So It works as intended ..
as It fullfills the requirement of Exercise "Create a for loop that prompts the user for a hobby 3 times." So it lets the code pass. :slight_smile:


On a technical level the SCT "works as intended" however, it doesn't from a learning perspective. My concern isn't that Python can still process the code correctly, it's that the goal of the exercise isn't understood correctly.


The SCT is not all that strict and a lot of incorrect code slips past. The main thing is that if the exercise is done correctly, and the user passes, these other flaws were allowed. The SCT has not been repaired for over two years and will not be revisited again. We consider a bug something that blocks a user from passing when they have the correct code according to the instructions.


The instructions seem pretty clear to me.

hobbies = []
for i in range(3):
    hobbies.append(raw_input("Enter a hobby to add to the list: "))


This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.