0% completed
Ceiling of a Number (medium)
.....
.....
.....
Anonymous
· 3 years ago
[1, 1, 1, 1, 1] 1
Anonymous
· 3 years ago
My code failed on a test case that I think is incorrect.
Given: [1, 1, 1, 1, 1] 1
The result should be 0 whereas the test expects 2. which makes no sense.
Anonymous
· 3 years ago
Testcase:
[1, 1, 1, 1, 1] 1
Test case expected result: 2
Correct result: 0
The test cases claim 2 is the correct result when the correct answer is clearly 0
Anonymous
· 3 years ago
Hi,
Could somebody extend the explanation about it? I think that's pretty important but I don't think that I understand.
Anonymous
· 4 years ago
Would it be correct in the floor solution to return either end or mid outside the loop? Since integer division "rounds down" so end and mid should always be equivalent by that point.
Anonymous
· 5 years ago
Are repeated integers meant to be handed with this solution? For example, for arguments: ([4, 6, 6, 6, 10], 6)
The result is 2. Reading the prompt it is unclear if this is sufficient or if the answer should be 1 in this case.
Reading Progress
0%