You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
At the print_winner function, I noticed that check50 only checks for one specific output format: printf("%s\n", name);
For example, if I use: printf("The winner of the election is %s\n", name);
check50 returns an error, even though the output conveys the same information. This isn't a bug in check50 for Tideman, as it is designed to check only for the expected format.
It would be helpful if the CS50x course page provided a clearer explanation of the expected output format in the print_winner function.
Currently, the instructions on the course page (CS50 Tideman Problem) state:
The function should print out the name of the candidate who is the source of the graph. You may assume there will not be more than one source.
I suggest updating it to:
The function should print out the name of the candidate who is the source of the graph. You may assume there will not be more than one source. Your program should output only the candidate's name followed by a newline (\n).
This small clarification could help avoid confusion for future students.
Thanks!
The text was updated successfully, but these errors were encountered:
Stefanelll
changed the title
Add More Details to print_winner Function
CS50x tideman - Add More Details to print_winner Function
Mar 8, 2025
Hello!
At the
print_winner
function, I noticed that check50 only checks for one specific output format:printf("%s\n", name);
For example, if I use:
printf("The winner of the election is %s\n", name);
check50
returns an error, even though the output conveys the same information. This isn't a bug incheck50
for Tideman, as it is designed to check only for the expected format.It would be helpful if the CS50x course page provided a clearer explanation of the expected output format in the
print_winner
function.Currently, the instructions on the course page (CS50 Tideman Problem) state:
I suggest updating it to:
This small clarification could help avoid confusion for future students.
Thanks!
The text was updated successfully, but these errors were encountered: