Skip to main content
2 votes

Check50 says the answer is wrong in the outdated.py problem but it is right. Help, how to solve?

Check50 is inputting a space before the nine, like this: "_9/8/1636" (with the _ in place of a space). Does your code handle that?
Rafael Luis Ferreira's user avatar
1 vote
Accepted

Why is my program returning YYYY-DD-MM instead of YYYY-MM-DD in the output? What am I getting wrong?

From the python doc [strptime usage] Parse a string into a datetime object given a corresponding format text is sent to the function with m/d/Y format That correction should fix the "order"...
DinoCoderSaurus's user avatar
1 vote

outdated : code not rejecting incorrectly formatted inputs

Here is some pseudo-code to get you started. It outlines the basic logic, but you have to add the code to implement that logic. while True: date = input('Enter Date: ') if [your test to check ...
kcw78's user avatar
  • 922
1 vote

Outdated problem cs50 python

You have many problems in your code. You never return anything from parse_date so formatted_date will always be False. You seem to possibly be relying on an implicit return of True but this is an ...
UpAndAdam's user avatar
  • 1,681
1 vote
Accepted

Inifinite loop for outdated problem

Adding another answer based on your new code. I'm giong to make some changes in that code and point out my changes with comments. NOTE THIS ANSWER ACTUALLY HAS AN ERROR IN IT WHICH I HAVE DELIBERATELY ...
UpAndAdam's user avatar
  • 1,681
1 vote

Inifinite loop for outdated problem

So many problems here. Strongly suggest you break the problem into subproblems. This is the way in programming. Writing one big huge long main function is a nono. It's hard to read, it's hard to ...
UpAndAdam's user avatar
  • 1,681
1 vote

Issues with Testing CS50P Problem Set 3, Outdated, Mismatch between the "How to Test" instructions and check50

This isn't an answer (per se), but shows the output I get when I run check50 against my code. As you can see, it expects a re-prompt, and I get a green smiley.
kcw78's user avatar
  • 922

Only top scored, non community-wiki answers of a minimum length are eligible