#is this code correct
12 messages · Page 1 of 1 (latest)
What do the tests say when you run them?
If year % 400 != 0 and year % 100 == 0
What track? What do the tests say? @winter cypress
We actively try not giving students complete answers so that they can work towards it themselves and learn in the process.
That's part of the condition of the task since the person is close to the solution. I just wanted to help.
Right. But we actively try to help by giving hints and examples, not final solutions.
@winter cypress Let me help you a little bit.
When I took your code, copied it into the online editor and clicked "Run Tests", I got this test result:
9 tests failed
FAILED
Test 1
Leap > year not divisible by 4 in common year
Code Run
self.assertIs(leap_year(2015), False)
Test Failure
AssertionError: 'its non leap year' is not False
Do you understand this result?
Do you understand the message of the AssertionError ("'its non leap year' is not False")?
I actually didn’t understand the testing part
Oh okay lol this was kind of tricky one
Tysm guys for your help